Part Number Hot Search : 
SI230 AUG04F48 HCPL7840 APT30 TA0301A 54ACT174 AQW454 5KE200
Product Description
Full Text Search
 

To Download AT89EB5114-TGSIL Datasheet File

  If you can't view the Datasheet, Please click here to try to view without PDF Reader .  
 
 


  Datasheet File OCR Text:
  rev. 4311a?8051?01/05 1 features  80c51 compatible ? two i/o ports ? two 16-bit timer/counters ? 256 bytes ram  4 kbytes rom or 4 kbytes flash program memory  256 bytes eeprom (stack die packaging technology on so20 package)  x2 speed improvement capability (6 clocks/machine cycle)  10-bit, 6 channels a/d converter ? one-channel with progammable gain and rectifying amplifier (accuracy +/- 5%) ? voltage reference for a/d & external analog  hardware watchdog timer  programmable i/o mode: standard c51, input only, push-pull, open drain  asynchronous port reset  triple system clock ? crystal or ceramic oscillator (24 mhz) ? rc oscillator (12 mhz), with calibration factor using external r and c (accuracy +/- 3.5% with ideal r and c) ? rc oscillator, low power consumption (12 mhz low accuracy) ? programmable prescaler  one pwm unit block with: ? 16-bits programmable counter ? 3 independent modules  one pwm unit block with: ? 16 bits programmable counter ? 1 module  interrupt structure with: ? 7 interrupt sources, ? 4 interrupt priority levels  power control modes: ?idle mode ? power-down mode ? power fail detect, power on reset ? quiet mode for a to d conversion  power supply: 3 to 3.6v  temperature range: -40 to 85 o c  package: so20, so24 (upon request) description the at8xeb5114 is a high performance version of the 80c51 8-bit microcontroller in a low pin count package. the at8xeb5114 retains all the features of the standard 80c51 with 4 kbytes pro- gram memory, 256 bytes of internal ram, a 7-source, 4-level interrupt system, an on- chip oscillator and two timers/counters. at8xeb5114 may include a serial two wire interface eeprom housed together with the microcontroller die in the same package. the at8xeb5114 is dedicated for analog interfacing applications. for this, it has a 10- bit, 6 channels a/d converter and two pwm units; these pwm blocks provide pwm generation with variable frequency and pulse width. in addition, the at8xeb5114 has a hardware watchdog timer and an x2 speed improvement mechanism. the x2 feature allows to keep the same cpu power at a divided by two oscillator frequency. the prescaler allows to decrease cpu and periph- erals clock frequency. the fully static design of the at8xeb5114 allows to reduce system power consumption by bringing the clock frequency down to any value, even dc, without loss of data. low-pin-count 8-bit microcontroller with a/d converter at83eb5114 at89eb5114
2 4311a?8051?01/05 the at8xeb5114 has 3 software-selectable modes of reduced activity for further reduc- tion in power consumption. in idle mode the cpu is frozen while the peripherals are still operating. in quiet mode, only the a/d converter is operating. in power-down mode the ram is saved and all other functions are inop erative. three oscillator sources, crystal, precision rc and low power rc, provide versatile power management. the at8xeb5114 is available in low pin count packages (rom and flash versions). figure 1. block diagram timer 0 int ram 256 t0 xtal2 xtal1 cpu timer 1 int1 ctrl int0 (2) (2) (3) port 3 p4.0-3 ib-bus watch dog vss vcc (2): alternate function of port 3 rom 4 k *8 x8 w0ci w0m0-2 xtal osc rc osc (2) (3) (3): alternate function of port 4 port 4 p3.0-5(so20) or 7(so24) pwmu0 w1m0 (2) pwmu1 rst a/d converter vref ain0-2,4-5 (2,3) vref generator w1ci (3) x1-20 ain3 r vcca vssa t1 256 b 2 wires interface or rc osc (12 mhz) (12 mhz) flash/ee 4k*8 ale (2) (3) (3) c (so20) eeprom parallel i/o ports
3 4311a?8051?01/05 pin configuration p3.0/w0m0 p4.3/ain3/int1 1 p3.5/w1m0 xtal2 rst xtal1 vss p4.0/ain0/w0ci p4.2/ain2/w1ci p4.1/ain1/t1 vref vcca vssa r c 2 3 4 5 6 7 8 9 10 20 19 18 17 16 15 14 13 12 11 vcc p3.3/w0m2/ain4 p3.4/t0/ain5 p3.2/int0 p3.1/w0m1 so20 p3.1/w0m1 p4.3/ain3/int1 1 p3.6 c xtal1 xtal2 nc p4.0/ain0/w0ci p4.2/ain2/w1ci p4.1/ain1/t1 vref vcca vssa nc r 2 3 4 5 6 7 8 9 10 24 23 22 21 20 19 18 17 16 15 rst p3.3/w0m2/ain4 p3.4/t0/ain5 p3.5/ w1m0 p3.2/int0 so24 p3.7 11 12 p3.0/w0m0 vss 14 13 vcc no ee
4 4311a?8051?01/05 pin description so20 so24 mnemonic type name and function 12 14 v ss power ground: 0v reference 18 22 vssa power analog ground: 0v reference for analog part 11 13 v cc power power supply: this is the power supply voltage for normal, idle and power-down operation. 19 23 vcca power analog power supply: this is the power supply voltage for analog part this pin must be connected to power supply. 20 24 vref analog vref: a/d converter positive reference input, out put of the internal voltage reference 14 17 xtal1 i input to the inverting oscillator amplifier and input to the internal clock generator circuit 15 18 xtal2 o output from the inverting oscillator amplifier. this pin can?t be connected to the ground. 17 20 r analog resistor input for the precision rc oscillator 16 19 c analog capacitor input for the precision rc oscillator 13 15 rst i/o reset input with integrated pull-up a low level on this pin for two machine cycles while the oscillator is running, resets the device. p3.0-p3.7 i/o port 3: port 3 is an 8-bit programmable i/o port with internal pull-ups. see ?port types? on page 32. for a description of i/o ports. port 3 also serves the special features of the 80c51 family, as listed below. 10 11 i/o w0m0 (p3.0): external i/o for pwmu 0 module 0 910 i/o w0m1 (p3.1): external i/o for pwmu 0 module 1 89 i/o int0 (p3.2): external interrupt 0 55 i/o w0m2 / ain4 (p3.3): external i/o for pwmu 0 module 2. p3.3 is also an input of the analog to digital converter. 66 i/o t0 / ain5(p3.4): timer 0 external input. p3.4 is also an input of the analog to digital converter. 78 i/o w1m0 (p3.5): external i/o for pwmu 1 module 0, c an also be used to output the external clocking signal p4.0-p4.3 i/o port 4 : port 4 is an 4-bit programmable i/o port wit h internal pull-ups. see ?port types? on page 32. for a description of i/o ports. port 4 is also the input port of the analog to digital converter 11 i/o ain0 (p4.0): a/d converter input 0 w0ci: count input of pwmu0 22 i/o ain1 (p4.1): a/d converter input 1 t1: timer 1 external input 33 i/o ain2 (p4.2): a/d converter input 2 w1ci: count input of pwmu1 44 i/o ain3 (p4.3): a/d converter input 3, programmable gain int1 : external interrupt 1
5 4311a?8051?01/05 sfr mapping the special function registers (sfrs) of the at8xeb5114 belong to the following categories:  c51 core registers: acc, auxr, auxr1, b, dph, dpl, psw, sp, fcon, hsb  i/o port registers: p3, p4, p3m1, p3m2, p4m1  timer registers: tcon, th0, th1, tl0, tl1, tmod  power and clock control registers: ckcon, ckrl, cksel, oscbfa, osccon, pcon  interrupt system registers: ien0, iph0, ipl0, ior  watchdog timer: wdtrst, wdtprg  pwm0 registers: w0ch, w0cl, w0con, w0fh, w0fl, w0ic, w0mod, w0r0h, w0r0l, w0r1h, w0r1l,w0r2h, w0r2l  pwm1registers: w1ch, w1cl, w1con, w1fh, w1fl, w1ic, w1r0h, w1r0l  adc registers: adca, adcf, adclk, adcon, addh, addl
6 4311a?8051?01/05 note: 1. "c", value defined by the hardware security byte, see table 2 on page 15 table 1. sfr addresses and reset values 0/8 1/9 2/a 3/b 4/c 5/d 6/e 7/f f8h w1con xxx0 0000 w1fh 0000 0000 w1fl 0000 0000 w1ch 0000 0000 w1cl 0000 0000 w1ic 0000 0000 ffh f0h b 0000 0000 adclk 0000 0000 adcon 0000 0000 addl xxxxxx00 addh 0000 0000 adcf 0000 0000 adca 0000 0000 f7h e8h w0con 00xx 0000 w0mod 00xx x000 w0fh 0000 0000 w0fl 0000 0000 w0ch 0000 0000 w0cl 0000 0000 w0ic 0000 0000 hsb 1111 xx11 efh e0h acc 0000 0000 p3m2 0000 0000 e7h d8h w0r0h 0000 0000 w0r0l 0000 0000 w0r1h 0000 0000 w0r1l 0000 0000 w0r2h 0000 0000 w0r2l 0000 0000 df h d0h psw 0000 0000 fcon 1111 1111 p3m1 0000 0000 p4m1 0000 0000 d7h c8h w1r0h 0000 0000 w1r0l 0000 0000 cf h c0h p4 xxxx 1111 c7h b8h ipl0 x000 0000 bfh b0h p3 1111 1111 iph0 x000 0000 b7h a8h ien0 0000 0000 afh a0h auxr1 xxxx 0xx0 ior xxxxxx00 wdtrst xxxxxxxx wdtprg xxxx x000 a7h 98h oscbfa 0111 0110 9fh 90h ckrl xxxx 1000 97h 88h tcon 0000 0000 tmod 0000 0000 tl0 0000 0000 tl1 0000 0000 th0 0000 0000 th1 0000 0000 auxr 0xx0 xxx0 ckcon xxxx xxx0 8fh 80h sp 0000 0111 dpl 0000 0000 dph 0000 0000 cksel xxxx xxcc osccon xxxx xxcc pcon 00xx xx00 87h 0/8 1/9 2/a 3/b 4/c 5/d 6/e 7/f
7 4311a?8051?01/05 mnemonicadd name 76543210 acc e0h accumulator adca f7h adc amplifier configuration - - - - - ac3e ac3g1 ac3g0 adcf f6h adcf register - - ch5 ch4 ch3 ch2 ch1 ch0 adclk f2h adc clock prescaler selre f prs6 prs5 prs4 prs3 prs2 prs1 prs0 adcon f3h adc control register quietm psidle aden adeoc adsst sch2 sch1 sch0 addh f5h adc data high byte register adat9 adat8 adat7 adat6 adat5 adat4 adat3 adat2 addl f4h adc data low byte register - - - - - - adat1 adat0 auxr 8eh auxiliary register dpu - - lowvd - - - - auxr1 a2h auxiliary register 1 - - - - - - - dps b f0h b register ckcon 8fh clock control register - - - - - - - x2 ckrl 97h clock prescaler register - - - - ckrl3 ckrl2 ckrl1 ckrl0 cksel 85h clock selection register - - - - - - cks1 cks0 dph 83h data pointer high byte dpl 82h data pointer low byte fcon d1h auxiliary register fpl3 fpl2 fpl1 fpl0 fps fmod1 fmod0 fbusy hsb efh hardware security byte x2 rst_osc1 rst_osc0 rst_oclk - - lb1 lb0 ien0 a8h interrupt enable register ea eadc ew1 ew0 et1 ex1 et0 ex0 ior a5h interrupt option register - - - - - - esb1 esb0 iph0 b7h interrupt priority register - padch pw1h pw0h pt1h px1h pt0h px0h ipl0 b8h interrupt priority register - padc pw1 pw0 pt1 px1 pt0 px0 oscbfa 9fh oscillator b frequency adjust oscbfa7 oscbfa6 oscbfa5 oscbfa4 oscbfa3 oscbfa2 oscbfa1 oscbfa0 osccon 86h clock control register - - - oscbry lcken osccen oscben oscaen p3 b0h port 3 register p3m1 d5h port 3 output configuration p3m1.7 p3m1.6 p3m1.5 p3m1.4 p3m1.3 p3m1.2 p3m1.1 p3m1.0 p3m2 e4h port 3 output configuration p3m2.7 p3m2.6 p3m2.5 p3m2.4 p3m2.3 p3m2.2 p3m2.1 p3m2.0 p4 c0h port 4 register p4m1 d6h port 4 output configuration p4m1.7 p4m1.6 p4m1.5 p4m1.4 p4m1.3 p4m1.2 p4m1.1 p4m1.0 pcon 87h power modes control register smod1 smod0 - - gf1 gf0 pd idl psw d0h program status word cy ac f0 rs1 rs0 ov f1 p sp 81h stack pointer tcon 88h timer/counter control register tf1 tr1 tf0 tr0 ie1 it1 ie0 it0 th0 8ch timer 0 high byte registers th0.7 th0.6 th0.5 th0.4 th0.3 th0.2 th0.1 th0.0 th1 8dh timer 1 high byte registers th1.7 th1.6 th1.5 th1.4 th1.3 th1.2 th1.1 th1.0 tl0 8ah timer 0 low byte registers tl0.7 tl0.6 tl0.5 tl0.4 tl0.3 tl0.2 tl0.1 tl0.0 tl1 8bh timer 1 low byte registers tl1.7 tl1.6 tl1.5 tl1.4 tl1.3 tl1.2 tl1.1 tl1.0
8 4311a?8051?01/05 tmod 89h timer/counter mode register gate1 c/t1# m11 m01 gate0 c/t0# m10 m00 w0ch ech pwmu0 counter high control w0c15 w0c14 w0c13 w0c12 w0c11 w0c10 w0c9 w0c8 w0cl edh pwmu0 counter low control w0c7 w0c6 w0c5 w0c4 w0c3 w0c2 w0c1 w0c0 w0con e8h pwmu0 control register w0up w0r - - w0os w0en2 w0en1 w0en0 w0fh eah pwmu0 frequency high control w0f15 w0f14 w0f13 w0f12 w0f11 w0f10 w0f9 w0f8 w0fl ebh pwmu0 frequency low control w0f7 w0f6 w0f5 w0f4 w0f3 w0f2 w0f1 w0f0 w0ic eeh pwmu0 interrupt configuration w0cf w0cf2 w0cf2 w0cf0 w0ecf w0ecf2 w0ecf1 w0ecf0 w0mod e9h pwmu0 counter mode register w0cps1 w0cps0 - - - w0inv2 w0inv1 w0inv0 w0r0h d9h pwmu0 module 0 high toggle w0r0h15 w0r0h14 w0r0h13 w0r0h12 w0r0h11 w0r0h10 w0r0h9 w0r0h8 w0r0l dah pwmu0 module 0 low toggle w0r0h7 w0r0h6 w0r0h5 w0r0h4 w0r0h3 w0r0h2 w0r0h1 w0r0h0 w0r1h dbh pwmu0 module 1high toggle w0r1h15 w0r1h14 w0r1h13 w0r1h12 w0r1h11 w0r1h10 w0r1h9 w0r1h8 w0r1l dch pwmu0 module1 low toggle w0r1h7 w0r1h6 w0r1h5 w0r1h4 w0r1h3 w0r1h2 w0r1h1 w0r1h0 w0r2h ddh pwmu0 module 2 high toggle w0r2h15 w0r2h14 w0r2h13 w0r2h12 w0r2h11 w0r2h10 w0r2h9 w0r2h8 w0r2l deh pwmu0 module 2 low toggle w0r2h7 w0r2h6 w0r2h5 w0r2h4 w0r2h3 w0r2h2 w0r2h1 w0r2h0 w1ch fch pwmu1 counter high control w1c15 w1c14 w1c13 w1c12 w1c11 w1c10 w1c9 w1c8 w1cl fdh pwmu1 counter low control w1c7 w1c6 w1c5 w1c4 w1c3 w1c2 w1c1 w1c0 w1con f8h pwmu1 control register w1up w1r - w1oclk w1cps1 w1cps0 w1inv0 w1en0 w1fh fah pwmu1 frequency high control w1f15 w1f14 w1f13 w1f12 w1f11 w1f10 w1f9 w1f8 w1fl fbh pwmu1 frequency low control w1f7 w1f6 w1f5 w1f4 w1f3 w1f2 w1f1 w1f0 w1ic feh pwmu1 interrupt configuration w1cf - - w1cf0 w1ecof - - w0ecf0 w1r0h c9h pwmu1 module 0 high toggle w1r0h15 w1r0h14 w1r0h13 w1r0h12 w1r0h11 w1r0h10 w1r0h9 w1r0h8 w1r0l cah pwmu1 module 0 low toggle w1r0h7 w1r0h6 w1r0h5 w1r0h4 w1r0h3 w1r0h2 w1r0h1 w1r0h0 wdtrst a6h watchdog timer enable register wdtprg a7h watchdog timer duration prg - - - - - s2 s1 s0 mnemonicadd name 76543210
9 4311a?8051?01/05 power monitor the power monitor function supervises the evolution of the voltages feeding the micro- controller, and if needed, suspends its activity when the detected value is out of specification. it warrants proper startup when at8xeb5114 is powered up and prevents code execu- tion errors when the power supply becomes lower than the functional threshold. this chapter describes the functions of the power monitor. description in order to startup and to properly maintain the microcontroller operation, vcc has to be stabilized in the vcc operating range and the oscillator has to be stabilized with a nomi- nal amplitude compatible with logic threshold. in order to be sure the oscillator is stabilized, there is an internal counter which main- tains the reset during 1024 clock periods in case the oscillator selected is the osc a and 64 clock periods in case the oscillator used is osc b or osc c. this control is carried out during thr ee phases: the power-up, normal operation and stop. in accordance with the following requirements:  it guarantees an operational reset when the microcontroller is powered-up, and  a protection if the power supply goes below minimum operating vcc figure 2. power monitor block diagram power monitor diagram the power monitor monitors the power-supply in order to detect any voltage drops which are not in the target specification. the power monitor block verifies two kinds of situation that may occur:  during the power-up condition, when vcc reaches the product specification,  during a steady-state condition, when vcc is at nominal value but disturbed by any undesired voltage drops. figure 2 shows some configurations which can be handled by the power monitor. external power-supply vcc internal reset power fail detector power up detector
10 4311a?8051?01/05 figure 3. power-up and steady-state conditions monitored the por/pfd forces the cpu into reset mode when vcc reaches a voltage condition which is out of specification. the thresholds and their functions are:  vpfdp: the vcc has reached a minimum functional value at power-up. the circuit leaves the reset mode  vpfdm: the vcc has reached a low threshold functional value for the microcontroller. an internal reset is set. glitch filtering prevents the system from reset when short duration glitches are carried on vcc power-supply (see ?electrical characteristics? on page 84.). in case vcc is below vpfdp, lowvd bit in auxr (see table 12 on page 23) is cleared by hardware. this bit allows the user to know if the voltage is below vpfdp. note: for proper reset operation v cca and v cc must be considered together (same power source). however, to improve the noise immunity, it is better to have two decou- pling networks close to power pins (one for v cca /v ssa pair and one for v cc /v ss pair). power-up steady state condition vcc t reset vpfdp vpfdm tg vcc tr
11 4311a?8051?01/05 clock system overview the at8xeb5114 oscillator system provides a reliable clocking system with full master- ing of speed versus cpu power trade-off. several clock sources are possible:  external clock input  high speed crystal or ceramic oscillator  integrated accurate oscillator with external r and c.  low power consumption integrated rc oscillator without external components. the at8xeb5114 needs 6 clock periods per machine cycle when the x2 function is set. however, the selected clock source can be divided by 2-32 before clocking the cpu and the peripherals. by default, the active oscillator after reset is the high speed crystal/ceramic oscillator. any two bits in a hardware configuration byte programmed by a flash programmer or by metal mask can activate any other one. the clock system is controlled by several sfr registers: ckcon, cksel, ckrl, oscon, pcon and hsb which is the hardware security byte. blocks description the at8xeb5114 includes three oscillators:  crystal oscillator optimized for 24 mhz.  1 accurate oscillator with a typical frequency of 12 mhz.  1 low power oscillator with a typical frequency of 14 mhz. figure 4. functional block diagram xtal2 xtal1 pwdosc ckrl 2 down to 32 prescaler-divider 11 10 oscout xtal_osc rc_osc oscben oscaen cks x2 0 1 mux filter + osca oscb ckidle ck idle cpu clock peripherals clock pwd ckout ckadc quiet a/d clock r rc_osc oscc c freq. adjust lcken osccen oscbry 01
12 4311a?8051?01/05 crystal oscillator: osca the crystal oscillator uses two external pins, xtal1 for input and xtal2 for output. oscaen in osccon register is an enable si gnal for the crystal oscillator or for the external oscillator input that can be provided on xtal1. high accurate rc oscillator: oscb the high accuracy rc oscillator needs exte rnal r and c components to assure the proper accuracy; its typical frequency is 12 mhz. frequency accuracy is a function of external r and c accuracy. it is recommended to use 0.5% or better for r and 1% for c components. (typical values are r = 49.9 k and c = 560 pf) this oscillator has two modes.  oscben = 1 and lcken = 0: standard accuracy mode(typical frequency 12 mhz)  oscben = 1 and lcken = 1: high accuracy mode (typical frequency 12 mhz). the oscb oscillator is based on a low frequency rc oscillator and a vco. when locked, the oscillator frequency is defined by the following formula: f = 3*[oscbfa+1]/(r.c). with c including parasitic capacitances. because the oscillator is based on a pll, it needs several periods to reach its final accuracy. as soon as this accuracy is reached, the oscbry bit in osccon register is set by hardware. the internal frequency is locked on the external rc time constant. so it is possible to adjust frequency by lower than 1% steps with the oscbfa register. however the frequency adjustment is limited to +/-15% around 12 mhz. the frequency can be adjusted until 15% around 12 mhz by oscbfa register. oscben and lcken are in the osccon register. low power consumption oscillator: oscc the low power consumption rc oscillator doesn?t need any external components. more- over its consumption is very low. its typical frequency is 14 mhz. note that this on-chip oscillator has a +/- 40% frequency tolerance and may not be suitable for use in certain applications. oscc is set by osccen bit in osccon. clock selector cks1 and cks0 bits in cksel register are used to select the clock source. osccen bit in osccon register is used to enable the low power consumption rc oscillator. oscben bit in osccon register is used to enable the high accurate rc oscillator. oscaen bit in osccon register is used to enable the crystal oscillator or the external oscillator input. x2 feature the at8xeb5114 core needs only 6 clock periods per machine cycle. this feature called ?x2? provides the following advantages:  divides frequency crystals by 2 (cheaper crystals) while keeping same cpu power.  saves power consumption while keeping same cpu power (oscillator power saving).  saves power consumption by dividing dynamically the operating frequency by 2 in operating and idle modes.  increases cpu power by 2 while keeping same crystal frequency. in order to keep the original c51 compatibility, a divider by 2 is inserted between the xtal1 signal and the main clock input of the core (phase generator). this divider may be enabled or disabled by software.
13 4311a?8051?01/05 description the clock for the whole circuit and peripherals is first divided by two before being used by the cpu core and the peripherals. this allows any cyclic ratio to be accepted on xtal1 input. in x2 mode, as this divider is bypassed, the signals on xtal1 must have a cyclic ratio from 40 to 60%. figure 4 shows the clock generation block diagram. x2 bit is validated on the rising edge of the xtal1 2 to avoid glitches when switching from x2 to standard mode. figure 5 shows the switching mode waveforms. figure 5. mode switching waveforms the x2 bit in the ckcon register (see table 7 on page 18) allows to switch from 12 clock periods per instruction to 6 clock periods and vice versa. clock prescaler before supplying the cpu and the peripherals, the main clock is divided by a factor from 2 to 32, as defined by the ckrl register (see table 6 on page 18). the cpu needs from 12 to 16*12 clock periods per instruction. this allows:  to accept any cyclic ratio on xtal1 input.  to reduce cpu power consumption. note: the number of bits of the prescaler is optimized in order to provide a low power con- sumption in low speed mode (see section ?electrical characteristics?, page 84). prescaler divider on reset a hardware reset selects the start oscillator depending on the rst1_osc and rst0_osc bits contained on the hardware security byte register (see table 2 on page 15). it also selects the prescaler divider as follows:  ckrl = 8h: internal clock = oscout / 16 (slow cpu speed at reset, thus lower power consumption) x2 = 0,  sel_osc1 and sel_osc0 bits selects osca, oscb or oscc, depending on the value of the rst_osc1 and rst_osc0 configuration bits.  after reset, any value between fh down to 0h can be written by software into ckrl sfr in order to divide frequency of the selected oscillator: ? ckrl = 0h: minimum frequency = oscout / 32 ? ckrl = fh: maximum frequency = oscout / 2 the frequency of the cpu and peripherals clock ckout is related to the frequency of the main oscillator oscout by the following formula: f ckout = f oscout / (32 - 2*ckrl) xtal1:2 xtal1 cpu clock x2 bit x2 mode std mode std mode f osc
14 4311a?8051?01/05 some examples can be found in the table below:  a software instruction which set x2 bit disables the prescaler/divider, so the internal clock is either osca, oscb or oscc depending on sel_osc1 and sel_osc0 bits. f oscout mhz x2 ckrl f ckout mhz 12 0 f 6 12 0 e 3 12 1 x 12
15 4311a?8051?01/05 registers hardware security byte the security byte sets the starting microcontroller options and the security levels. the default options are x1 mode, oscillator a and divided by 16 prescaler. table 2. hardware security byte (hsb) power configuration register - hsb (s:efh) hsb = 1111 1x11b 765 4 3210 x2 rst_osc1 rst_osc0 rst_oclk ckrlrv - lb1 lb0 bit number bit mnemonic description 7x2 x2 mode clear to force x2 mode (ckout = oscout) set to use the prescaler mode (ckout = oscout / (2*(16-m))) 6 rst_osc1 oscillator bit 1 on reset and oscillator bit 0 on reset 11: allows osca 10: allows oscb 01: allows oscc 00: reserved 5 rst_osc0 4rst_oclk output clocking signal after reset clear to start the microcontroller with a low level on p3.5 followed by an output clocking signal on p3.5 as soon as the micr ocontroller is started. this signal has is a 1/3 high 2/3 low signal. its frequency is equal to (ckout / 3). set to start on normal conditions: no signal on p3.5 which is pulled up. 3ckrlrv ckrl reset value if set, the microcontroller starts with the prescaler reset value = xxxx 1000 (oscout = ckout/16). if clear, the microcontroller starts with a prescaler reset value = xxxx 1111 (oscout = ckout/2). 2- reserved 1-0 lb1-0 user program lock bits see table 61 on page 81
16 4311a?8051?01/05 clock control register the clock control register is used to define the clock system behavior. table 3. oscon register osccon - clock control register (86h) reset value = xxx0 0"rst_osc1 .rst_osc0""rst_osc1.rst_osc0 ""rst_osc1.rst_osc0" b not bit addressable note: before changing oscillator selection in cksel, be sure that the oscillator you select is started. osca is ready as soon as oscary is set by hardware, oscb and oscc are ready after 4 clock periods. in case you want to use oscb locked, be sure that oscb is started before setting lcken bit. then, wait until oscbry is set by hardware to be sure that the accurate frequency is reached. oscillator b frequency adjust register the oscb frequency adjust register is used to adjust the frequency in case of external components inaccuracies. it allows a frequency variation about 15% around 12 mhz with a step of around 1%. 76543210 - - oscary oscbry lcken osccen oscben oscaen bit number bit mnemonic description 7- reserved the value read from this bit is indeterminate. do not set this bit. 6- reserved the value read from this bit is indeterminate. do not set this bit. 5 oscary oscillator a ready when set, this bit indicates that oscillator a is ready to be used. 4 oscbry oscillator b ready when set, this bit indicates that oscillator b is ready to be used in high accurate mode. 3lcken lock enable when set, this bit allows to increase the accuracy of oscb by locking this oscillator on external rc time constant. 2 osccen enable low power consumption rc oscillator this bit is used to enable the low power consumption oscillator 0: the oscillator is disabled 1: the oscillator is enabled. 1oscben enable high accuracy rc oscillator this bit is used to enable the high accurate rc oscillator 0: the oscillator is disabled 1: the oscillator is enabled. 0oscaen enable crystal oscillator this bit is used to enable the crystal oscillator 0: the oscillator is disabled 1: the oscillator is enabled.
17 4311a?8051?01/05 table 4. oscbfa register oscbfa- oscillator b frequency adjust register (9fh) reset value = 0111 0110b not bit addressable clock selection register the clock selection register is used to define the clock system behavior. table 5. cksel register cksel - clock selection register (85h) reset value = xxxx xx"rst_osc1" "rst_osc0" b not bit addressable 7 6 5 4 3 2 1 0 oscbfa7 oscbfa6 oscbfa5 oscbfa4 oscbfa3 oscbfa2 oscbfa1 oscbfa0 bit number bit mnemonic description 7-0 oscbfa 7-0 oscb frequency adjust the reset value to have 12 mhz is 0111 0110. it is possible to modify this value in order to increase or decrease the frequency. 76543210 ------cks1cks0 bit number bit mnemonic description 7- reserved the value read from this bit is indeterminate. do not set this bit. 6- reserved the value read from this bit is indeterminate. do not set this bit. 5- reserved the value read from this bit is indeterminate. do not set this bit. 4- reserved the value read from this bit is indeterminate. do not set this bit. 3- reserved the value read from this bit is indeterminate. do not set this bit. 2- reserved the value read from this bit is indeterminate. do not set this bit. 1cks1 active clock selector 1and active clock selector 0 these bits are used to select the active oscillator 11: the crystal oscillator is selected 10: the high accuracy rc oscillator is selected 01: the low power consumption rc oscillator is selected 00: reserved 0cks0
18 4311a?8051?01/05 clock prescaler register this register is used to reload the clock prescaler of the cpu and peripheral clock. table 6. ckrl register ckrl - clock prescaler register (97h) reset value = xxxx 1000b not bit addressable clock control register this register is used to control the x2 mode of the cpu and peripheral clock. table 7. ckcon register ckcon - clock control register (8fh) reset value = 0000 0000b not bit addressable 7 6 5 4 3 2 1 0 - - - - m bit number bit mnemonic description 7-4 - reserved 3-0 ckrl 0000b: division factor equal 32 1111b: division factor equal 2 m: division factor equal 2*(16-m) 76543210 -------x2 bit number bit mnemonic description 7-1 - reserved 0x2 x2 mode set to force x2 mode (ckout = oscout) clear to use the prescaler mode (ckout = oscout / (2*(16-m)))
19 4311a?8051?01/05 power modes overview as seen in the previous chapter it is possible to modify the at8xeb5114 clock manage- ment in order to have less consumption. for applications where power consumption is a critical factor, three power modes are provided:  normal (running) mode  idle mode  power-down mode in order to increase adc accuracy, a quiet mode also exits. this mode is a pseudo idle mode in which the cpu and all the peripherals except the ad converter are disabled. power modes are controlled by pcon sfr register. operating modes table 8 summarizes all the power modes and states that at8xeb5114 can encounter. it shows which parts of at8xeb5114 are running depending on the operating mode. table 8. operating modes normal mode in normal mode, the oscillator, the cpu and the peripherals are running. the prescaler can also be activated.  the cpu and the peripherals clock depends on the software selection using ckcon, osccon, cksel and ckrl registers  cks bits select either osca, oscb, or oscc  ckrl register determines the frequency of the selected clock, unless x2 bit is set. in this case the prescaler/divider is not used, so cpu core needs only 6-clock periods per machine cycle. it is always possible to switch dynamically by software from one to another oscillator by changing cks bits, a synchronization cell allows to avoid any spike during transition. idle mode the idle mode allows to reduce consumpt ion by freezing the cpu. all the peripherals continue running. entering idle mode an instruction that sets pcon.0 causes t hat to be the last instruction executed before going into idle mode. in idle mode, the internal clock signal is gated off to the cpu, but not to the interrupt, and the peripheral functions. the cpu status is entirely preserved: the stack pointer, program counter, program status word, accumulator and all other registers maintain operating mode prescaler oscillator por cpu peripherals power down x under reset a, b or c x start x a, b or c x x running (x) a, b or c x x x idle (x) a, b or c x x quiet (x) a, b or c x only adc
20 4311a?8051?01/05 their data during idle. the port pins hold the logical states they had at the time idle was activated. ale and psen are held at logi c high levels. the different operating modes are summarized on table 10 on page 21. exit from idle mode there are two ways to terminate idle mode. activation of any enabled interrupt will cause pcon.0 to be cleared by hardware, te rminating idle mode. the interrupt will be serviced, and following reti the next instruction to be executed will be the one following the instruction that put the device into idle. exit from idle mode will leave the oscillators control bits on oscon and cks registers unchanged. the flag bits gf0 and gf1 can be used to give an indication if an interrupt occurred dur- ing normal operation or during an idle mode. for example, an instruction that activates idle mode can also set one or both flag bits. when idle is terminated by an interrupt, the interrupt service routine can examine the flag bits. the other way of terminating the idle mode is with a hardware reset. since the clock oscillator is still running, the hardware reset needs to be held active for only two machine cycles (24 oscillator periods) to complete the reset. in both cases, pcon.0 is cleared by hardware. quiet mode the quiet mode is a pseudo idle mode in which the cpu and all the peripherals except the ad converter are down. for more details, see ?analog-to-digital converter (adc)? on page 57. power-down mode to save maximum power, a power-down mode can be invoked by software (refer to table 11 on page 22). in power-down mode, the oscillator is stopped and the instruction that invoked power-down mode is the last instruction executed. the internal ram and sfrs retain their value until the power-down mode is terminated. v cc can be lowered to save further power. entering power-down mode an instruction that sets pcon.1 causes t hat to be the last instruction executed before going into the power-down mode. the ports status under power-down is the previous status before entering this power mode. exit from power-down mode either a hardware reset or an external interrupt (low level) on int0 or int1 (if enabled) can cause an exit from power-down. to properly terminate power-down, the reset or external interrupt should not be executed before v cc is restored to its normal operating level and must be held active long enough for the oscillator to restart and stabilize. exit from power-down by external interrupt does not affect the sfrs and the internal ram content. figure 6. power-down exit waveform by a hardware reset, the cpu will restart in the mode defined by the rst_osc1 and rst_osc0 bits in hsb. interrupt osc power-down phase oscillator restart phase active phase active phase
21 4311a?8051?01/05 by int1 and int0 interruptions (if enabled), the oscillators control bits on oscon and cksel will be kept, so the selected oscillator before entering in power-down mode will be activated. only external interrupts int0 and int1 are useful to exit from power-down. note: exit from power down mode doesn?t depend on it0 and it1 configurations. it is only pos- sible to exit from power down mode on a low level on these pins. holding the pin low restarts the oscillator but bringing the pin high completes the exit as detailed in figure 6. when both interrupts are enabled, the oscillator restarts as soon as one of the two inputs is held low and power down exit will be completed when the first input is released. in this case the higher priority interrupt service routine is executed. table 9 shows the state of ports during idle and power-down modes. table 9. ports state mode program memory port3 port4 idle internal port data port data power down internal port data port data table 10. operating modes pd idle cks1 cks0 osccen oscben oscaen selected mode comment 0 0 1 1 x x 1 normal mode a osca: xtal clock x x 1 1 x x 0 invalid no active clock 0 0 1 0 x 1 x normal mode b, oscb: high accuracy rc clock x x 1 0 x 0 x invalid no active clock 0 0 0 1 1 x x normal mode c, oscc: low consumption rc clock x x 0 1 0 x x invalid no active clock 0111 x x 1idle mode a the cpu is off, osca supplies the peripherals 0110 x 1 xidle mode b the cpu is off, oscb supplies the peripherals 0101 1 x xidle mode c the cpu is off, oscc supplies the peripherals 1 x x x x x x power down the cpu is off, osca, oscb and oscc are stopped
22 4311a?8051?01/05 power modes control registers table 11. pcon register pcon (s:87h) power configuration register reset value = 00xx xx00b 7 6 5 4 3 2 1 0 - - - - gf1 gf0 pd idl bit number bit mnemonic description 7 reserved 6 reserved 5 reserved 4 reserved 3gf1 general purpose flag 1 set and cleared by user for general purpose usage. 2gf0 general purpose flag 0 set and cleared by user for general purpose usage. 1pd power-down mode bit cleared by hardware when an interrupt or reset occurs. set to activate the power-down mode. if idl and pd are both set, pd takes precedence. 0idl idle mode bit cleared by hardware when an interrupt or reset occurs. set to activate the idle mode. if idl and pd are both set, pd takes precedence.
23 4311a?8051?01/05 auxr register reset value = 0xx0 xxxxb not bit addressable table 12. auxr register auxr - auxiliary register (8eh) 7 6 5 4 3 2 1 0 dpu - - lowvd - - - - bit number bit mnemonic description 7dpu disable pull up set to disable each pull up on all ports. clear to connect all pull-ups on each port. 6- reserved the value read from this bit is i ndeterminate. do not set this bit. 5- reserved the value read from this bit is i ndeterminate. do not set this bit. 4lowvd low voltage detection this bit is clear by hardware when the supply voltage is under vpfdp value. this bit is set by hardware as soon the supply voltage is greater than vpfdp value. 3-1 - reserved the value read from this bit is i ndeterminate. do not set this bit. 0- reserved the value read from this bit is i ndeterminate. do not set this bit.
24 4311a?8051?01/05 timers/counters introduction the at8xeb5114 implements two general-purpose, 16-bit timers/counters. although they are identified as timer 0, timer 1, they can be independently configured each to operate in a variety of modes as a timer or as an event counter. when operating as a timer, a timer/counter runs for a programmed length of time, then issues an interrupt request. when operating as a counter, a timer/counter counts negative transitions on an external pin. after a preset number of counts, the counter issues an interrupt request. the timer registers and associated control registers are implemented as addressable special function registers (sfrs). two of the sfrs provide programmable control of the timers as follows:  timer/counter mode control register (tmod) and timer/counter control register (tcon) control both timer 0 and timer 1. the various operating modes of each timer/counter are described below. timer/counter operations a basic operation is timer registers thx and tlx (x = 0, 1) connected in cascade to form a 16-bit timer. setting the run control bit (trx) in the tcon register (see figure 15) turns the timer on by allowing the selected input to increment tlx. when tlx overflows it increments thx and when thx overflows it sets the timer overflow flag (tfx) in the tcon register. setting the trx does not clear the thx and tlx timer reg- isters. timer registers can be accessed to obtain the current count or to enter preset values. they can be read at any time but the trx bit must be cleared to preset their val- ues, otherwise the behavior of the timer/counter is unpredictable. the c/tx# control bit selects timer operation or counter operation by selecting the divided-down system clock or the external pin tx as the source for the counted signal. the trx bit must be cleared when changing the operating mode, otherwise the behavior of the timer/counter is unpredictable. for timer operation (c/tx# = 0), the timer register counts the divided-down system clock. the timer register is incremented once every peripheral cycle. for counter operation (c/tx# = 1), the timer register counts the negative transitions on the external input pin tx. the external input is sampled during every s5p2 state. the programmer?s guide describes the notation for the states in a peripheral cycle. when the sample is high in one cycle and low in the next one, the counter is incremented. the new count value appears in the register during the next s3p1 state after the transition has been detected. since it takes 12 states (24 oscillator periods in x1 mode) to recog- nize a negative transition, the maximum count rate is 1/24 of the oscillator frequency in x1 mode. there are no restrictions on the duty cycle of the external input signal, but to ensure that a given level is sampled at least once before it changes, it should be held for at least one full peripheral cycle. timer 0 timer 0 functions as either a timer or an event counter in four operating modes. figure 7 to figure 10 show the logic configuration of each mode. timer 0 is controlled by the four lower bits of the tmod register (see figure 16) and bits 0, 1, 4 and 5 of the tcon register (see figure 15). the tmod register selects the method of timer gating (gate0), timer or counter operation (t/c0#) and the operating mode (m10 and m00). the tcon register provides timer 0 control functions: overflow flag (tf0), run control bit (tr0), interrupt flag (ie0) and interrupt type control bit (it0). for normal timer operation (gate0= 0), setting tr0 allows tl0 to be incremented by the selected input. setting gate0 and tr0 allows external pin int0# to control timer
25 4311a?8051?01/05 operation. timer 0 overflow (count rolls over from all 1s to all 0s) sets the tf0 flag and generates an interrupt request. it is important to stop the timer/counter before changing modes. mode 0 (13-bit timer) mode 0 configures timer 0 as a 13-bit timer which is set up as an 8-bit timer (th0 reg- ister) with a modulo-32 prescaler implemented with the lower five bits of the tl0 register (see figure 7). the upper three bits of the tl0 register are indeterminate and should be ignored. prescaler overflow increments the th0 register. figure 7. timer/counter x (x= 0 or 1) in mode 0 mode 1 (16-bit timer) mode 1 configures timer 0 as a 16-bit timer with the th0 and tl0 registers connected in a cascade (see figure 8). the selected input increments the tl0 register. figure 8. timer/counter x (x = 0 or 1) in mode 1 mode 2 (8-bit timer with auto- reload) mode 2 configures timer 0 as an 8-bit timer (tl0 register) that automatically reloads from the th0 register on overflow (see figure 9). tl0 overflow sets the tf0 flag in the tcon register and reloads tl0 with the contents of th0, which is preset by the soft- ware. when the interrupt request is serviced, the hardware clears tf0. the reload leaves th0 unchanged. the next reload value may be changed at any time by writing it to the th0 register. trx tcon reg tfx tcon reg 0 1 gatex tmod reg overflow timer x interrup t reques t c/tx# tmod reg tlx (5 bits) thx (8 bits) intx# tx f ckidle / 6 trx tcon reg tfx tcon reg 0 1 gatex tmod reg overflow timer x interrup t reque st c/tx# tmod reg tlx (8 bits) thx (8 bits) intx# tx f ckidle / 6
26 4311a?8051?01/05 figure 9. timer/counter x (x = 0 or 1) in mode 2 mode 3 (two 8-bit timers) mode 3 configures timer 0 so that registers tl0 and th0 operate as 8-bit timers (see figure 10). this mode is provided for applications requiring an additional 8-bit timer or counter. tl0 uses the timer 0 control bits c/t0# and gate0 in the tmod register, and tr0 and tf0 in the tcon register in the normal manner. th0 is locked into a timer function (counting f uart ) and takes over use of the timer 1 interrupt (tf1) and run con- trol (tr1) bits. thus, operation of timer 1 is restricted when timer 0 is in mode 3. figure 10. timer/counter 0 in mode 3: two 8-bit counters timer 1 timer 1 is identical to timer 0 except for mode 3 which is a hold-count mode. the fol- lowing comments help to understand the differences:  timer 1 functions as either a timer or an event counter in the three operating modes. figure 7 to figure 9 show the logical configuration for modes 0, 1, and 2. mode 3 of timer 1 is a hold-count mode.  timer 1 is controlled by the four high-order bits of the tmod register (see figure 16) and bits 2, 3, 6 and 7 of the tcon register (see figure 15). the tmod register selects the method of timer gating (gate1), timer or counter operation (c/t1#) and the operating mode (m11 and m01). the tcon register provides timer 1 control functions: overflow flag (tf1), run control bit (tr1), interrupt flag (ie1) and the interrupt type control bit (it1).  timer 1 can serve as the baud rate generator for the serial port. mode 2 is best suited for this purpose. trx tcon reg tfx tcon reg 0 1 gatex tmod reg overflow timer x interrup t reques t c/tx# tmod reg tlx (8 bits) thx (8 bits) intx# tx f ckidle / 6 tr0 tcon.4 tf0 tcon.5 int0# 0 1 gate0 tmod.3 overflow timer 0 interrup t reques t c/t0# tmod.2 tl0 (8 bits) tr1 tcon.6 th0 (8 bits) tf1 tcon.7 overflow timer 1 interrup t reques t t0 f ckidle f ckidle / 6
27 4311a?8051?01/05  for normal timer operation (gate1= 0), setting tr1 allows tl1 to be incremented by the selected input. setting gate1 and tr1 allows external pin int1# to control timer operation.  timer 1 overflow (count rolls over from all 1s to all 0s) sets the tf1 flag and generates an interrupt request.  when timer 0 is in mode 3, it uses timer 1?s overflow flag (tf1) and run control bit (tr1). for this situation, use timer 1 only for applications that do not require an interrupt (such as a baud rate generator for the serial port) and switch timer 1 in and out of mode 3 to turn it off and on.  it is important to stop the timer/counter before changing modes. mode 0 (13-bit timer) mode 0 configures timer 1 as a 13-bit timer, which is set up as an 8-bit timer (th1 reg- ister) with a modulo-32 prescaler implemented with the lower 5 bits of the tl1 register (see figure 7). the upper 3 bits of tl1 register are indeterminate and should be ignored. prescaler overflow increments the th1 register. mode 1 (16-bit timer) mode 1 configures timer 1 as a 16-bit ti mer with th1 and tl1 registers connected in cascade (see figure 8). the selected input increments the tl1 register. mode 2 (8-bit timer with auto- reload) mode 2 configures timer 1 as an 8-bit timer (tl1 register) with automatic reload from the th1 register on overflow (see figure 9). tl1 overflow sets the tf1 flag in the tcon register and reloads tl1 with the contents of th1, which is preset by the software. the reload leaves th1 unchanged. mode 3 (halt) placing timer 1 in mode 3 causes it to halt and hold its count. this can be used to halt timer 1 when the tr1 run control bit is not available i.e. when timer 0 is in mode 3.
28 4311a?8051?01/05 registers table 13. tcon (s:88h) timer/counter control register reset value = 0000 0000b 76543210 tf1 tr1 tf0 tr0 ie1 it1 ie0 it0 bit number bit mnemonic description 7tf1 timer 1 overflow flag cleared by the hardware when processor vectors to interrupt routine. set by the hardware on timer 1 register overflows. 6tr1 timer 1 run control bit clear to turn off timer/counter 1. set to turn on timer/counter 1. 5tf0 timer 0 overflow flag cleared by the hardware when processor vectors to interrupt routine. set by the hardware on timer 0 register overflows. 4tr0 timer 0 run control bit clear to turn off timer/counter 0. set to turn on timer/counter 0. 3ie1 interrupt 1 edge flag cleared by the hardware as soon as the interrupt is processed. set by the hardware when external interrupt is detected on the int1 pin. 2it1 interrupt 1 type control bit clear to select low level active for external interrupt 1 (int1 ). set to select sensitive edge trigger for external interrupt 1. the sensitive edge (rising or falling) is determined by esb1 value (edge selection bit 1) in ior (interrupt option register). 1ie0 interrupt 0 edge flag cleared by the hardware as soon as the interrupt is processed. set by the hardware when external interrupt is detected on int0 pin. 0it0 interrupt 0 type control bit clear to select low level active trigger for external interrupt 0 (int0 ). set to select sensitive edge trigger for external interrupt 0. the sensitive edge (rising or falling) is determined by esb0 (edge selection bit 0) in ior (interrupt option register).
29 4311a?8051?01/05 table 14. ior (s:a5h) interrupt option register. reset value = xxxx xx00b 76543210 ------esb1esb0 bit number bit mnemonic description 7-2 - reserved the value read from this bit is indeterminate. do not set this bit. 1esb1 edge selection bit for int1 clear to select falling edge sensitive for int1 pin. set to select rising edge sensitive for int1 pin. 0esb0 edge selection bit for int0 clear to select falling edge sensitive for int0 pin. set to select rising edge sensitive for int0 pin.
30 4311a?8051?01/05 table 15. tmod register tmod (s:89h) timer/counter mode control register. reset value = 0000 0000b table 16. th0 register th0 (s:8ch) timer 0 high byte register. reset value = 0000 0000b 76543210 gate1 c/t1# m11 m01 gate0 c/t0# m10 m00 bit number bit mnemonic description 7gate1 timer 1 gating control bit clear to enable timer counter 1 whenever tr1 bit is set. set to enable timer counter 1 only while int1# pin is high and tr1 bit is set. 6c/t1# timer 1 counter/timer select bit clear for timer operation: timer 1 counts the divided-down system clock. set for counter operation: timer 1 counts negative transitions on external pin t1. 5m11 timer 1 mode select bits m11 m 01 o perating mode 0 0 mode 0: 8-bit timer/counter (th1) with 5-bit prescaler (tl1). 0 1 mode 1: 16-bit timer/counter. 1 0 mode 2: 8-bit auto-reload timer/counter (tl1). reloaded from th1 at overflow. 1 1 mode 3:timer 1 halted. retains count. 4m01 3gate0 timer 0 gating control bit clear to enable timer counter 0 whenever tr0 bit is set. set to enable timer counter 0 only while int0# pin is high and tr0 bit is set. 2c/t0# timer 0 counter/timer select bit clear for timer operation: timer 0 counts the divided-down system clock. set for counter operation: timer 0 counts negative transitions on external pin t0. 1m10 timer 0 mode select bit m10 m 00 o perating mode 0 0 mode 0:8-bit timer/counter (th0) with 5-bit prescaler (tl0). 0 1 mode 1:16-bit timer/counter. 1 0 mode 2:8-bit auto-reload timer/counter (tl0). reloaded from th0 at overflow 1 1 mode 3:tl0 is an 8-bit timer/counter th0 is an 8-bit timer using timer 1?s tr0 and tf0 bits. 0m00 76543210 bit number bit mnemonic description 7:0 high byte of timer 0.
31 4311a?8051?01/05 table 17. tl0 register tl0 (s:8ah) timer 0 low byte register. reset value = 0000 0000b table 18. th1 register th1 (s:8dh) timer 1 high byte register. reset value = 0000 0000b table 19. tl1 register tl1 (s:8bh) timer 1 low byte register. reset value = 0000 0000b 76543210 bit number bit mnemonic description 7:0 low byte of timer 0. 76543210 bit number bit mnemonic description 7:0 high byte of timer 1. 76543210 bit number bit mnemonic description 7:0 low byte of timer 1.
32 4311a?8051?01/05 ports the at8xeb5114 has 2 i/o ports, port 3, and port 4. all port3 and port4 i/o port pins on the at8xeb5114 may be software configured to one of four types on a bit-by-bit basis, as shown below in table 20. these are: quasi-bidirec- tional (standard 80c51 port outputs), push-pull, open drain, and input only. two configuration registers for each port select the output type for each port pin. table 20. port output configuration setting using pxm1 and pxm2 registers (3 < x < 4) port types quasi-bidirectional output configuration the default port output configuration for standard at8xeb5114 i/o ports is the quasi- bidirectional output that is common on the 80c51 and most of its derivatives. this output type can be used as both an input and output without the need of reconfiguring the port. this is possible because when the port outputs a logic high, it is weakly driven, allowing an external device to pull the pin low. when the pin is pulled low, it is driven strongly and able to sink a fairly large current. these features are somewhat similar to an open drain output except that there are three pull-up transistors in the quasi-bidirectional output that serve different purposes. one of these pull-ups, called the "weak" pull-up, is turned on whenever the port latch for the pin contains a logic 1. the weak pull-up sources a very small current that will pull the pin high if it is left floating. a second pull-up, called the "medium" pull-up, is turned on when the port latch for the pin contains a logic 1 and the pin itself is also at a logic 1 level. this pull-up provides the primary source current for a quasi-bidirectional pin that is outputting a 1. if a pin that has a logic 1 on it is pulled low by an external device, the medium pull-up turns off, and only the weak pull-up remains on. in order to pull the pin low under these conditions, the external device has to sink enough current to overpower the medium pull-up and take the voltage on the port pin below its input threshold. the third pull-up is referred to as the "strong " pull-up. this pull-up is used to speed up low-to-high transitions on a quasi-bidirectional port pin when the port latch changes from a logic 0 to a logic 1. when this occurs, the strong pull-up turns on for a brief time, two cpu clocks, in order to pull the port pin high quickly. then it turns off again. the quasi-bidirectional port configuration is shown in figure 11. pxm1.(2y+1) bit pxm1.(2y) bit (0< y< 3) port output mode 0 0 quasi bidirectional 01push-pull 1 0 input only (high impedance) 1 1 open drain pxm2.(2y-7) bit pxm2.(2y-8) bit (4< y< 7) port output mode 0 0 quasi bidirectional 01push-pull 1 0 input only (high impedance) 1 1 open drain
33 4311a?8051?01/05 figure 11. quasi-bidirectional output open drain output configuration the open drain output configuration turns off all pull-ups and only drives the pull-down transistor of the port driver when the port latch contains a logic 0. to be used as a logic output, a port configured in this manner must have an external pull-up, typically a resis- tor tied to v dd . the pull-down for this mode is the same as the quasi-bidirectional mode. the open drain port configuration is shown in figure 12. figure 12. open drain output push-pull output configuration the push-pull output configuration has the same pull-down structure as both the open drain and the quasi-bidirectional output modes, but provides a continuous strong pull-up when the port latch contains a logic 1. the push-pull mode may be used when more source current is needed from a port output. the push-pull port configuration is shown in figure 13. 2 cpu input pin strong medium n pp weak p clock delay port latch data data dpu auxr.7 input pin n port latch data data
34 4311a?8051?01/05 figure 13. push-pull output input only configuration the input only configuration is a pure input with neither pull-up nor pull-down. the input only configuration is shown in figure 13. figure 14. input only ports description ports p3 and p4 the inputs of each i/o port of the at8xeb5114 are ttl level schmitt triggers with hysteresis. input pin strong n p port latch data data input pin data
35 4311a?8051?01/05 registers table 21. p3m1 register p3m1 address (d5h) reset value = 0000 0000 table 22. p3m2 register p3m2 address (e4h) reset value = 0000 0000 76543210 p3m1.7 p3m1.6 p3m1.5 p3m1.4 p3m1.3 p3m1.2 p3m1.1 p3m1.0 bit number bit mnemonic description 7-6 p3m1.7-6 port 3.3 output configuration bit see table 20 for configuration definition 5-4 p3m1.5-4 port 3.2 output configuration bit see table 20 for configuration definition 3-2 p3m1.3-2 port 3.1 output configuration bit see table 20 for configuration definition 1-0 p3m1.1-0 port 3.0 output configuration bit seetable 20 for configuration definition 76543210 p3m2.7 p3m2.6 p3m2.5 p3m2.4 p3m2.3 p3m2.2 p3m2.1 p3m2.0 bit number bit mnemonic description 7-6 p3m2.7-6 port 3.7 output configuration bit seetable 20 for configuration definition 5-4 p3m2.5-4 port 3.6 output configuration bit see table 20 for configuration definition 3-2 p3m2.3-2 port 3.5 output configuration bit see table 20 for configuration definition 1-0 p3m2.1-0 port 3.4 output configuration bit see table 20 for configuration definition
36 4311a?8051?01/05 table 23. p4m1 register p4m1 address (d6h) reset value = 0000 0000 76543210 p4m1.7 p4m1.6 p4m1.5 p4m1.4 p4m1.3 p4m1.2 p4m1.1 p4m1.0 bit number bit mnemonic description 7-6 p4m1.7-6 port 4.3 output configuration bit see table 20 for configuration definition 5-4 p4m1.5-4 port 4.2 output configuration bit see table 20 for configuration definition 3-2 p4m1.3-2 port 4.1 output configuration bit see table 20 for configuration definition 1-0 p4m1.1-0 port 4.0 output configuration bit see table 20 for configuration definition
37 4311a?8051?01/05 dual data pointer register (ddptr) the additional data pointer can be used to speed up code exec ution and reduce code size in a number of ways. the dual dptr structure is a way by which the chip will specify the address of an exter- nal data memory location. there are two 16-bit dptr registers that address the external memory, and a single bit called dps = auxr1/bit0 (see figure 15) that allows the pro- gram code to switch between them. figure 15. use of dual pointer external data memory auxr1(a2h) dps dph(83h) dpl(82h) 0 7 dptr0 dptr1
38 4311a?8051?01/05 note: user software should not write 1?s to reserved bits. these bits may be used in future 8051 family products to invoke new feature. in that case, the reset value of the new bit will be 0, and its active value will be 1. the value read from a reserved bit is indeterminate. table 24. auxr1: auxiliary register 1 76543210 -----0-dps bit number bit mnemonic description 7- reserved the value read from this bit is indeterminate. do not set this bit. 6- reserved the value read from this bit is indeterminate. do not set this bit. 5- reserved the value read from this bit is indeterminate. do not set this bit. 4- reserved the value read from this bit is indeterminate. do not set this bit. 3- reserved the value read from this bit is indeterminate. do not set this bit. 20 reserved always stuck at 0 1- reserved the value read from this bit is indeterminate. do not set this bit. 0dps data pointer selection clear to select dptr0. set to select dptr1.
39 4311a?8051?01/05 application software can take advantage of the additional data pointers to both increase speed and reduce code size, for example, block operations (copy, compare, search...) are well served by using one data pointer as a ?source? pointer and the other one as a ?destina- tion? pointer. assembly language ; block move using dual data pointers ; destroys dptr0, dptr1, a and psw ; note: dps exits opposite of entry state ; unless an extra inc auxr1 is added ; 00a2 auxr1 equ 0a2h ; 0000 909000mov dptr,#source ; address of source 0003 05a2 inc auxr1 ; switch data pointers 0005 90a000 mov dptr,#dest ; address of dest 0008 loop: 0008 05a2 inc auxr1 ; switch data pointers 000a e0 movx a,@dptr ; get a byte from source 000b a3 inc dptr ; increment source address 000c 05a2 inc auxr1 ; switch data pointers 000e f0 movx @dptr,a ; write the byte to dest 000f a3 inc dptr ; increment dest address 0010 70f6jnz loop ; check for 0 terminator 0012 05a2 inc auxr1 ; (optional) restore dps inc is a short (2 bytes) and fast (12 clocks) way to manipulate the dps bit in the auxr1 sfr. however, note that the inc instruction does not directly force the dps bit to a par- ticular state, but simply toggles it. in simple routines, such as the block move example, only the fact that dps is toggled in the proper sequence matters, not its actual value. in other words, the block move routine works the same whether dps is '0' or '1' on entry. observe that without the last instruction (inc auxr1), the routine will exit with dps in the opposite state.
40 4311a?8051?01/05 pwm unit 0 (pwmu0) the pwm unit 0 allows to generate precise pulse width modulation with variable duty cycle and frequency. the pwmu0 consists on a dedicated 16 bits auto reload counter/timer which serves as a time base for the generation of 3 independent pwm signals. its clock input can be programmed to count any one of the following signals:  peripheral clock, ckidle  timer 0 overflow  external input on w0ci (p4.0) the pwmu0 timer/counter shares several external i/o. these pins are listed below. if a port is not used for the pwmu0, it can still be used for standard i/o. pwmu0 timer the pwmu0 timer is a common 16 bits time base for all three modules (see figure 16). the timer count source is determined from the w0cps1 and w0cps0 bits in the w0mod register (see table 26) and can be programmed to run at:  peripheral clock, ckidle  timer 0 overflow  external input on w0ci (p1.2) the output frequency depends on the timer source and also on the w0f registers. indeed, the timer/counter counts from zero up to a value loaded via sw0f registers. each time the counter is higher or equal to the sw0f shadow registers value, w0c reg- isters are automatically reloaded with zero. if the w0up bit is set, the shadow sw0f registers are reloaded with the contents of w0f registers when the w0c overtakes. this prevents frequency drift (see figure 16.). note: if the pwmu0 is off (w0r bit in w0con not set), the contents of w0fh and w0fl are automatically copied on the shadow registers sw0fh and sw0fl. this allows to charge the correct comparison values in order to have the wanted frequency as soon as the pwm is turned on. pwmu0 component external i/o pin 16-bit counter w0ci (p4.0) 16-bit module 0 w0m0 (p3.0) 16-bit module 1 w0m1 (p3.1) 16-bit module 2 w0m2 (p3.3)
41 4311a?8051?01/05 figure 16. pwmu0 timer/counter table 25. w0con: pwmu0 control register w0con - pwmu0 control register (e8h) reset value = 00xx 0000b bit addressable 76543210 w0up w0r - - w0os w0en2 w0en1 w0en0 bit number bit mnemonic description 7w0up pwmu0 update bit set by software to request the load of all shadow registers on the next overtaking of the w0c counter. reset by hardware after the loading of the shadow registers. 6w0r pwmu0 run control bit set by software to turn the pwmu0 counter on. must be cleared by software to turn the pwmu0 counter off. 5-4 - not used 3w0os pin w0m1 pwmu0 output selection 0 w0m1 is pwm module 1 xor pwm module2 output 1 w0m1 is pwm module 1 output 2w0en2 pwmu0 module 2 enable bit enable pwmu0 module 2 if set. 1w0en1 pwmu0 module 1 enable bit enable pwmu0 module 1if set. 0w0en0 pwmu0 module 0 enable bit enable pwmu0 module 0 if set. w0en2 w0en1 w0en0 w0ch w0cl to pwmu0 modules fckidle t0 ovf w0ci w0con sw0fh sw0fl w0os1 w0r w0up 16 bit up w0inv2 w0inv1 w0inv0 w0mod wops0 w0ps1 w0fh w0fl 0000 0000 16 bit comparator counter overtaking
42 4311a?8051?01/05 table 26. w0mod: pwmu0 counter mode register w0mod - pwmu0 counter mode register (e9h) reset value = 00xx x000b not bit addressable because they use the same timer, all three modules have the same frequency deter- mined by the shadow sw0f registers. table 27. w0fh: pwmu0 frequency high control register w0fh - pwmu0 frequency control register (eah) reset value = 1111 1111b not bit addressable 76543210 w0cps1 w0cps0 - - - w0inv2 w0inv1 w0inv0 bit number bit mnemonic description 7w0cps1 pwmu0 count pulse select bit1 6w0cps0 pwmu0 count pulse select bit0 cps1 cps0 selected pwmu0 input 00 internal clock f ckidle 01 reserved 10 timer 0 overflow 11 external clock input on w0ci at max rate = f ckidle /4 5-3 - not used 2w0inv2 pwmu0 module 2 inverter bit select the output pwm mode. if set, pwm module 2 output starts with high level. 1w0inv1 pwmu0 module 1 inverter bit select the output pwm mode. if set, pwm module 1 output starts with high level. 0w0inv0 pwmu0 module 0 inverter bit select the output pwm mode. if set, pwm module 0 output starts with high level. 76543210 w0f15 w0f14 w0f13 w0f12 w0f11 w0f10 w0f9 w0f8 bit number bit mnemonic description 7-0 w0f15-8 pwmu0 high bits counter control frequency the pwmu0 counter is counting from zero up to w1f15-0 value.
43 4311a?8051?01/05 table 28. w0fl: pwmu0 frequency low control register w0fl - pwmu0 frequency control register (ebh) reset value = 1111 1111b not bit addressable table 29. w0ch: pwmu0 counter high control register w0ch - pwmu0 counter control register (ech) reset value = 0000 0000b not bit addressable table 30. w0cl: pwmu0 counter low control register w0cl - pwmu0 counter control register (edh) reset value = 0000 0000b not bit addressable pwmu0 output generation all the pwmu0 modules have the same frequency determined by the w0f register. but each module has its own duty cycle determined by the w0rn register. (n is the module number). when the w0c content is lower than the value programmed via the w0rn registers, the output is the w0invn-bit (low if 0, high if 1). when it is equal or higher, the output is the opposite of this w0invn-bit (high if 0, low if 1). when the w0c content is higher than sw0f?s, an overtaking occurs. the counter value (w0c registers) is automatically reloaded with zero (see figure 16). if the w0up bit is high, the new comparison value is reloaded on the shadow sw0r0 registers with the 76543210 w0f7 w0f6 w0f5 w0f4 w0f3 w0f2 w0f1 w0f0 bit number bit mnemonic description 7-0 w0f7-0 pwmu0 low bits counter control frequency the pwmu0 counter is counting from zero up to wof15-0 value. 76543210 w0c15 w0c14 w0c13 w0c12 w0c11 w0c10 w0c9 w0c8 bit number bit mnemonic description 7-0 w0c15-8 pwmu0 high bits counter frequency. 76543210 w0c7 w0c6 w0c5 w0c4 w0c3 w0c2 w0c1 w0c0 bit number bit mnemonic description 7-0 w0c7-0 pwmu0 low bits counter frequency.
44 4311a?8051?01/05 content of the w0r0 registers (see figure 16). this method allows to change frequency and duty cycle without glitch. note: if the pwmu0 is off (w0r bit in w0con not set), w0rnh and w0rnl contents are auto- matically copied on the shadow registers sw0rnh and sw0rnln and the contents of w0fh and w0fl are automatically copied on the shadow registers sw0fh and sw0fl. this allows to charge the correct comparison values for each pwm module as soon as the pwmu0 timer/counter is turned on. figure 17. pwmu0 interrupt system the w0invn bits that allow output inversion are on the w0mod (w0 counter mode) register (see table 26.). table 31. w0rnh: pwmu0 module n high toggle register w0r0h - pwmu0 module 0 high toggle register (d9h) w0r1h - pwmu0 module 1 high toggle register (dbh) w0r2h - pwmu0 module 2 high toggle register (ddh) reset value = 0000 0000b not bit addressable 76543210 w0rnh15 w0rnh14 w0rnh13 w0rnh12 w0rnh11 w0rnh10 w0rnh9 w0rnh8 bit number bit mnemonic description 7-0 w0rnh 15-8 pwmu0 module n high toggle register when the counter exceeds this value, module n output toggles. w0ch w0cl sw0rnh sw0rnl w0rnh w0rnl 16 bits-comparator ? < overtaking module n output w0invn w0up
45 4311a?8051?01/05 table 32. w0rnl: pwmu0 module n low toggle register w0r0l - pwmu0 module 0 low toggle register (dah) w0r1l - pwmu0 module 1 low toggle register (dch) w0r2h - pwmu0 module 2 low toggle register (deh) reset value = 0000 0000b not bit addressable pwmu0 output selector in order to generate no recovery signal, it is possible to configure the microcontroller with the w0oc register to have pwmu0 module 1 xor pwmu0 module 2 on the w0m1 pin (see figure 18). figure 18. .pwmu0 output selector w0con and w0mod are detailed on table 25 and table 26. pwmu0 interrupt system each pwmu0 module can generate an interrupt. the w0ic register enables or disables interrupt and interrupt flags (see table 33). 76543210 w0rnl7 w0rnl6 w0rnl5 w0rnl4 w0rnl3 w0rnl2 w0rnl1 w0rnl0 bit number bit mnemonic description 7-0 w0rnl7-0 pwmu0 module n low toggle register when the counter exceeds this value, module n output toggles. w0m0 module 0 output w0m1 module 1 output module 2 output w0m2 w0en2 w0en1 w0en0 w0con w0os1 w0r w0up w0inv2 w0inv1 w0inv0 w0mod wops0 w0ps1 ?1? ?1? ?1?
46 4311a?8051?01/05 figure 19. pwmu0 interrupt configuration table 33. pwmu0 interrupt control register w0ic - pwmu0 interrupt control register (eeh) reset value = 0000 0000b not bit addressable 76543210 w0cf w0cf2 w0cf1 w0cf0 w0ecof w0ecf2 w0ecf1 w0ecf0 bit number bit mnemonic description 7w0cof pwmu0 counter overtaking flag set by hardware when the count er is higher or equal to sw0f?s value. cf flags an interrupt if bit w0ecof is set. w0cof can be set either by hardware or software but can only be cleared by software. 6w0cf2 pwmu0 module 2 toggle flag set by hardware when a match occurs. can also be set by software. must be cleared by software. 5w0cf1 pwmu0 module 1 toggle flag set by hardware when a match occurs. can also be set by software. must be cleared by software. 4w0cf0 pwmu0 module 0 toggle flag set by hardware when a match occurs. can also be set by software. must be cleared by software. 3w0ecof pwmu0 counter overtaking flag set to enable it on pwmu0 counter overtaking flag. 2w0ecf2 pwmu0 module 2 counter flag set to enable it on pwmu0 module 2 toggle flag. 1w0ecf1 pwmu0 module 1 counter flag set to enable it on pwmu0 module 1toggle flag. 0w0ecf0 pwmu0 module 0 counter flag set to enable it on pwmu0 module 0toggle flag. w0 w0 w0 w0 module 2 module 1 ie0.4 ie0.7 to interrupt priority decoder ew0 ea cf1 cf0 ecf1 ecf0 w0 cf2 w0 cof module 0 overtaking w0 w0 ecof ecf2 w0ic
47 4311a?8051?01/05 pwm unit 1 (pwmu1) the pwm unit 1 allows to generate precise pulse width modulation with variable duty cycle and frequency. the pwmu1 consists of a dedicated 16 bits auto reload counter/timer which serves as a time base for the generation of an independent pwm signal. its clock input can be programmed to count any one of the following signals:  peripheral clock, ckidle  timer 1 overflow  external input on w1ci (p4.2) the pwmu1 timer/counter shares two external i/o. these pins are listed below. if a port is not used for the pwmu1, it can still be used for standard i/o. pwmu1 timer the pwmu1 timer is a 16-bit timer (see figure 20). the timer count source is deter- mined from the w1cps1 and w1cps0 bits in the w1con register (see table 34) and can be programmed to run at:  peripheral clock, ckidle  timer 1 overflow  external input on w1ci (p4.2) the output frequency depends on the timer source and also on the w1f registers. the timer/counter counts from zero up to a value loaded via sw1f registers. each time the counter is higher or equal to the sw1f shadow registers value, w1c registers are auto- matically reloaded with zero. if the w1up bit is set, the shadow sw1f registers is reloaded with the contents of w1f registers wh en w1c overtakes. this allows to pre- vent frequency drift (see figure 20). note: if the pwmu1 is off (w1r bit in w1con not set), the contents of w1fh and w1fl are automatically copied on the shadow registers sw1fh and sw1fl. this allows to charge the correct comparison values in order to have the desired frequency as soon as the pwm is turned on. pwmu1 component external i/o pin 16-bit counter w1ci (p4.2) 16-bit module 0 w1m0 (p3.5)
48 4311a?8051?01/05 figure 20. pwmu1 timer/counter w1cps0 w1inv0 w1r w1con w1oclkw1cps1 w1up w1en0 w1ch w1cl to pwmu1 modules fckidle t0 ovf w1ci sw1fh sw1fl 16 bit up w1fh w1fl 0000 0000 16 bit comparator ? counter overtaking
49 4311a?8051?01/05 table 34. w1con: pwmu1 control register w1con - pwmu1 control register (f8h) reset value = 000?rst_oclk? 000?rst_oclk?b bit addressable table 35. w1fh: pwmu1 frequency high control register w1fh - pwmu1 frequency control register (fah) reset value = 1111 1111b not bit addressable 76543210 w1up w1r - w1oclk w1cps1 w1cps0 w1inv0 w1en0 bit number bit mnemonic description 7w1up pwmu1 update bit set by software to request the load of all shadow registers on the next overtaking of the w1c counter. reset by hardware after the loading of the shadow registers 6w1r pwmu1 run control bit set by software to turn the pwmu1 counter on. must be cleared by software to turn the pwmu1 counter off. 5- not used 4w1oclk output clocking control bit. this bit allows to choose between the output clocking signal and the pwm1m0 output. if set, the external clocking is chosen, if clear, pwm1m0 is chosen. 3w1cps1 pwmu1 count pulse select bit1 2w1cps0 pwmu count pulse select bit0 cps1 cps0 selected pwmu1 input 00 internal clock f ckidle 01 reserved 10 timer 1 overflow 11 external clock input on w1ci at max rate = f ckidle /4 1w1inv0 pwmu1 module 0 inverter bit select the output pwm mode. if set, pwm module 0 output starts with high level. 0w1en0 pwmu1 module 0 enable bit enable pwmu1 module 0 if set. if clear, p3.5 is an i/o port. 76543210 w1f15 w1f14 w1f13 w1f12 w1f11 w1f10 w1f9 w1f8 bit number bit mnemonic description 7-0 w1f15-8 pwmu1 high bits counter control frequency the pwmu1 counter is counting from zero up to w1f15-0 value.
50 4311a?8051?01/05 table 36. w1fl: pwmu1 frequency low control register w1fl - pwmu1 frequency control register (fbh) reset value = 1111 1111b not bit addressable table 37. w1ch: pwmu1 counter high control register w1ch - pwmu1 counter control register (fch) reset value = 0000 0000b not bit addressable table 38. w1cl: pwmu1 counter low control register w1cl - pwmu1 counter control register (fdh) reset value = 0000 0000b not bit addressable pwmu1 output generation all the pwmu1 modules have the same frequency determined by the w1f registers. however, each module has is own duty cycle determined by the w1rn registers. (n is the module number). when the w1c content is lower than the value programmed via w1rn registers, the output is the w1invn-bit (low if 0, high if 1). when it is equal or higher, the output is the opposite of this w1invn-bit (high if 0, low if 1). when the w1c content is higher than sw1f?s, an overtaking occurs. the counter value (w1c registers) is automatically reloaded with zero (see figure 21.). if the w1up bit is high, the new comparison value is reloaded on the shadow sw1r0 registers with the 76543210 w1f7 w1f6 w1f5 w1f4 w1f3 w1f2 w1f1 w1f0 bit number bit mnemonic description 7-0 w1f7-0 pwmu1 low bits counter control frequency the pwmu1 counter is counting from zero up to w1f15-0 value. 76543210 w1c15 w1c14 w1c13 w1c12 w1c11 w1c10 w1c9 w1c8 bit number bit mnemonic description 7-0 w1c15-8 pwmu1 high bits counter frequency 76543210 w1c7 w1c6 w1c5 w1c4 w1c3 w1c2 w1c1 w1c0 bit number bit mnemonic description 7-0 w1f7-0 pwmu1 low bits counter frequency
51 4311a?8051?01/05 content of the w1r0 registers (see figure 21.). this method allows to change frequency and duty cycle without glitch. note: if the pwmu1 is off (w1r bit in w0con not set), w1rnh and w1rnl contents are automatically copied on the shadow registers sw1rnh and sw1rnln and the contents of w1fh and w1fl are automatically copied on the shadow registers sw1fh and sw1fl. this allows to charge the correct comparison values for each pwm module as soon as the pwmu1 timer/counter is turned on. figure 21. pwmu1 interrupt system the w1inv0 bit that allows output inversion is on the w1con (w1 control) register (see table 34.). table 39. w1r0h: pwmu1 module 0 high toggle register w1r0h - pwmu1 module 0 high toggle register (c9h) reset value = 0000 0000b not bit addressable table 40. w1r0l: pwmu1 module 0 low toggle register w1r0l - pwmu1 module 0 low toggle register (cah) reset value = 0000 0000b not bit addressable 76543210 w1r0h15 w1r0h14 w1r0h13 w1r0h12 w1r0h11 w1r0h10 w1r0h9 w1r0h8 bit number bit mnemonic description 7-0 w1r0h 15-8 pwmu1 module 0 high toggle register when the counter exceeds this value, module 0 output toggles. 76543210 w1r0l7 w1r0l6 w1r0l5 w1r0l4 w1r0l3 w1r0l2 w1r0l1 w1r0l0 bit number bit mnemonic description 7-0 w1r0l7-0 pwmu1 module 0 low toggle register when the counter exceeds this value, module 0 output toggles. w1ch w1cl sw1r0h sw1r0l w1r0h w1r0l 16 bits-comparator ? < overtaking module 0 output w1inv0 w1up
52 4311a?8051?01/05 pwmu1 output selector as shown on figure 22., the pwmu1 can configure p3.5 to be used as  the pwmu1 module 0 output (w1r = 1 and w1en0 = 1)  the external clocking output (w1oclk = 1 and w1en0 = 1)  an i/o port (w1en0 = 0) this configuration is made via w1con register (see table 34.). by default, w1con register contains 00h. so p3.5 is configured as an i/o port. the w1inv0 bit allows to start pwmu1 module 0 period with a high (if set) or low level. figure 22. pwmu1 output selector pwmu1 interrupt system pwmu1 can generate an interrupt. the w1ic register enables or disables interrupt and interrupt flags (see table 41). figure 23. pwmu1 interrupt configuration module 0 output oclk w1cps01w1inv0 w1r w1con w1eclk w1up w1cps1 w1en0 w1m0 ?1? -w1 -w1 ie0.5 ie0.7 to interrupt priority decoder ew1 ea cf0 ecf0 - w1 cof module 0 overtaking w1 - ecof w1ic
53 4311a?8051?01/05 table 41. pwmu1 interrupt control register w1ic - pwmu1 interrupt control register (feh) reset value = 0000 0000b not bit addressable 76543210 w1cf - - w1cf0 w1ecf - - w1ecf0 bit number bit mnemonic description 7w1cof pwmu1 counter overtaking flag set by hardware when the counter roll s over. cf flags an interrupt if bit w1ecof is set. w1cof can be set either by hardware or soft ware but can only be cleared by software. 6-5 - not used 4w1cf0 pwmu1 module 0 toggle fla set by hardware when a match occurs. can also be set by software. must be cleared by software. 3w1ecof pwmu1 counter overtaking flag set to enable pwmu1 counter overtaking flag. 2-1 - not used 0w1ecf0 pwmu1 module 0 counter flag set to enable pwmu1 module 0toggle flag.
54 4311a?8051?01/05 watchdog timer at8xeb5114 contains a powerful programmable hardware watchdog timer (wdt) that automatically resets the chip if its software fails to reset the wdt before the selected time interval has elapsed. it permits large time-out ranking from 16 ms to 2s @fosc = 12 mhz. this wdt consists of a 14-bit counter plus a 7-bit programmable counter, a watchdog timer reset register (wdtrst) and a watchdog timer programmation (wdtprg) reg- ister. when exiting reset, the wdt is -by default- disabled. to enable the wdt, the user has to write the sequence 1eh and e1h into wdrst register. when the watchdog timer is enabled, it will increment every machine cycle while the oscillator is running and there is no way to disable the wdt except through reset (either hardware reset or wdt overflow reset). when wdt overflows, it will generate an output reset pulse at the rst pin. the reset pulse duration is 96xt osc , where t osc =1/f osc . to make the best use of the wdt, it should be serviced in those sections of code that will periodically be executed within the time required to prevent a wdt reset. the wdt is controlled by two registers (wdtrst and wdtprg) figure 24. watchdog timer reset decoder control wdtrst wr enable 14-bit counter 7-bit counter outputs f cpu_periph reset - - - - - 2 1 0 wdtprg
55 4311a?8051?01/05 figure 25. wdtprg register wdtprg - watchdog timer duration programming register (a7h). reset value = xxxx x000b the three lower bits (s0, s1, s2) located into wdtprg register permit to program the wdt duration. to compute wd time-out, the following formula is applied: note: note: value represents the decimal value of (s2 s1 s0) / ckrl represents the prescaler bit number bit mnemonic description 7- reserved the value read from this bit is i ndeterminate. do not set this bit. 6- reserved the value read from this bit is i ndeterminate. do not set this bit. 5- reserved the value read from this bit is i ndeterminate. do not set this bit. 4- reserved the value read from this bit is i ndeterminate. do not set this bit. 3- reserved the value read from this bit is i ndeterminate. do not set this bit. 2s2 watchdog timer duration selection bit 2 work in conjunction with bit 1 and bit 0. 1s1 watchdog timer duration selection bit 1 work in conjunction with bit 2 and bit 0. 0s0 watchdog timer duration selection bit 0 work in conjunction with bit 1 and bit 2. s2 s1 s0 machine cycle count 000 2 14 - 1 001 2 15 - 1 010 2 16 - 1 011 2 17 - 1 100 2 18 - 1 101 2 19 - 1 110 2 20 - 1 111 2 21 - 1 timeout fclkperiph () x 2 () x 2 12 2 14 2 svalue () 1 ? () 15 ckrl ? () -------------------------------------------------------------------------------------------------------- - =
56 4311a?8051?01/05 find hereafter computed time-out value for fosc = 12 mhz reset value = xxxx xxxxb the wdtrst register is used to reset/enable the wdt by writing 1eh then e1h in sequence. watchdog timer during power down mode and idle in power down mode the oscillator stops, which means the wdt also stops. while in power down mode the user does not need to service the wdt. there are 2 methods of exiting power down mode: by a hardware reset or via a level activated external interrupt which is enabled prior to entering power down mode. when power down is exited with hardware reset, servicing the wdt should occur as it normally does whenever at8xeb5114 is reset. exiting power down with an interrupt is significantly different. the interrupt is held low long enough for the oscillator to stabilize. when the interrupt is brought high, the interrupt is serviced. to prevent the wdt from resetting the device while the interrupt pin is held low, the wdt is not started until the interrupt is pulled high. it is suggested that the wdt be reset during the interrupt service for the interrupt used to exit power down. to ensure that the wdt does not overflow within a few states of exiting of power down, it is best to reset the wdt just before entering power down. in the idle mode, the oscillator continues to run. to prevent the wdt from resetting while in idle mode, the user should always set up a timer that will periodically exit idle, service the wdt, and re-enter idle mode. table 42. time-out computation @12 mhz s2 s1 s0 time-out for f osc =12 mhz 0 0 0 16.38 ms 0 0 1 32.77 ms 0 1 0 65.54 ms 0 1 1 131.07 ms 1 0 0 262.14 ms 1 0 1 524.29 ms 1 1 0 1.05 s 1 1 1 2.10 s table 43. wdtrst register 7 6 5 4 3 2 1 0 - - - - - - - -
57 4311a?8051?01/05 analog-to-digital converter (adc) this section describes the on-chip 10 bit analog-to-digital converter of the at8xeb5114. six adc channels are available for sampling of the external sources ain0 to ain5. an analog multiplexer allows the single adc converter to select one from the 6 adc chan- nels as adc input voltage (adcin). adcin is converted by the 10 bit-cascaded potentiometric adc. 8 to 10 bits resolution can only be reached while using an external voltage reference. for the precision conversion, set bits psidle and adsst in adcon register to start the conversion. the chip is in a pseudo-idle mode, the cpu doesn?t run but the periph- erals are always running. this mode allows digital noise to be lower, to ensure precise conversion. for accurate conversion, set bits quietm and adsst in adcon register to start the conversion. the chip is in a quiet mode, the ad is the only peripheral running. this mode allows digital noise to be as low as possible, to ensure high precision conversion. for these modes it is necessary to work with end of conversion interrupt, which is the only way to wake up the chip. if another interrupt occurs during the precision conversion, it will be treated only after this conversion is ended. features  6 channels with multiplexed inputs  one channel with input signal average extraction and programmable gain amplification.  10-bit cascaded potentiometric adc  typical conversion time 20 micro-seconds  zero error (offset) +/- 2 lsb max  external positive reference voltage range 2.4 to vcc  internal positive reference typical voltage 2.4 volt (1)  adcin range 0 to v ref  integral non-linearity typical 1 lsb (1)  differential non-linearity typical 0.5 lsb (1)  conversion complete flag or conversion complete interrupt  selected adc clock note: (1): see ?dc parameters for a/d converter? on page 88.
58 4311a?8051?01/05 adc i/o functions ainx are general i/o that are shared with the adc channels. the channel select bit in adcf register define which adc channel pin will be used as adcin. the remaining adc channels pins can be used as general purpose i/o or as the alternate function that is available. writings to the port register s which aren?t selected by the adcf will not have any effect. figure 26. adc description figure 27 shows the timing diagram of a complete conversion. for simplicity, the figure depicts the waveforms in idealized form and do not provide precise timing information. for adc characteristics and timing parameters refer to thesection ?dc parameters for a/d converter?, page 88. figure 27. timing diagram note: tsetup = 0 clk ain0/p4.0 ain1/p4.1 ain2/p4.2 ain3/p4.3 000 001 010 011 sch2 adcon.2 sch0 adcon.0 sch1 adcon.1 conv_ck aden adcon.5 adsst adcon.3 adeoc adcon.4 adc interrupt request eadc ie1.1 control avss sample and hold addh vref r/2r dac 8 10 + - addl 2 sar adcin vagnd selref adclk.7 2.4v aden adcon.5 * gain ain4/p3.3 ain5/p3.4 100 101 ac3e adca.2 r aden adsst adeoc t setup t conv conv_ck
59 4311a?8051?01/05 channel 3 amplifier and rectifying function if needed, the average value of the rectified signal on channel 3 can be extracted and amplified before a/d conversion as shown on figure 28. figure 28. channel 3 amplifier the main characteristics of this block are the following:  input signal level: sine wave centered around vssa, peak value from 70 to 550 mv depending on gain, frequency range from 35 to 70khz. be sure that the peak value on the amplifier output is lower than voltage supply.  gain: x5, x10, x15 and x20, selected using ac3e, ac3g1 and ac3g0 in adc amplifier register (see table 44 and table 52)  max time constant of the average value extraction: 0.5ms. when the gain is changed or when the signal levels changes from the minimum to the maximum value, a new measurement can be done after 10 time constant.  the amplifier needs 20us to fully load the adc hold capacitance so the adc conversion must occurs at least 20us after the amplified channel is sampled.  accuracy on amplification and extraction: +/- 5% note: the ain3 direct channel is not equivalent to the other channels. there is a serial resis- tance of around 100k ? between the pin and the adc input. so when the amplifier is bypassed, it is necessary to switch at least 20us the mux on ain3 input before starting a conversion. table 44. adcf register adca (s:f7h) adc amplifier configuration reset value = 0000 0000b ain3/p4.3 a/d input amplification (programmable gain) ac3g1 adcf.7 ac3e adcf.5 ac3g0 adcf.6 enable gain average value extraction 76543210 -----ac3eac3g1ac3g0 bit number bit mnemonic description 7-3 - not used 2ac3e enable channel 3 amplifier set to enable amplifier. clear for standby mode 1ac3g1 channel 3 amplifier gain ac3g1 ac3g0 0 0 gain x5 0 1 gain x10 1 0 gain x15 1 1 gain x20 0ac3g0
60 4311a?8051?01/05 adc converter operation a start of single a/d conversion is triggered by setting bit adsst (adcon.3). the busy flag adsst(adcon.3) remains set as long as an a/d conversion is running. after completion of the a/d conversion, it is cleared by hardware. when a conversion is running, this flag can be read only, a write has no effect. the end-of-conversion flag adeoc (adcon.4) is set when the value of conversion is available in addh and addl, it is cleared by software. if the bit eadc (ie0.6) is set, an interrupt occur when flag adeoc is set (see figure 30). clear this flag for re-arming the interrupt. the bits sch0 to sch2 in adcon register are used for the analog input channel selection. before starting normal power reduction modes the adc conversion has to be completed. table 45. selected analog input voltage conversion when the adcin is equal to varef the adc converts the signal to 3ffh (full scale). if the input voltage equals vagnd, the adc converts it to 000h. input voltage between varef and vagnd are a straight-line linear conversion. all other voltages will result in 3ffh if greater than varef and 000h if less than vagnd. note that adcin should not exceed varef absolute maximum range. clock selection the maximum clock frequency for adc (conv_ck for conversion clock) is defined in the section ?ac parameters?, page 88. a prescaler is featured to generate the conv_ck clock from the oscillator frequency. the prescaler value prs[6:0] is defined in the adclk register (see table 49 on page 64) sch2 sch1 sch0 selected analog input 000an0 001an1 010an2 011an3 100an4 101an5 110 111
61 4311a?8051?01/05 figure 29. a/d converter clock the conversion frequency conv_c k is derived from the oscillator frequency with the following formulas: f ckadc = f oscout / (32 - 2*ckrl), if x2=0 = f oscout , if x2=1 and f conv_ck = f ckadc / (2*prs), if prs > 0 f conv_ck = f ckadc / 256, if prs = 0 some examples can be found on table below: adc standby mode when the adc is not used, it is possible to set it in standby mode by clearing bit aden in adcon register. voltage reference the voltage reference can be either internal or external. as input, the v ref pin is used to enter the voltage reference for the a/d conversion. when the voltage reference is active, the v ref pin is an output. this voltage can be used for the a/d and for any other application requiring a voltage independent from the power supply. voltage typical value is 2.4 volt (see ?dc parameters for a/d converter? on page 88.) it adc management an interrupt end-of-conversion will occur when the bit adeoc is activated and the bit eadc is set. for re-arming the interrupt the bit adeoc must be cleared by software. figure 30. adc interrupt structure f oscout mhz x2 ckrl f ckadc mhz prsw f conv_ck khz conversion time s 16 0 f 8 12 333 33 16 1 na 16 32 250 44 prescaler prs a/d converter conv_ck ckadc / 2 adeoc adcon.4 eadc ie0.6 adci
62 4311a?8051?01/05 accuracy improvement on analog to digital conversion using th e internal voltage reference overview the internal vref absolute accuracy is around 4%. this variation is mainly due to the temperature, the process, and the voltage variations. in order to increase the accuracy of the measurements made thanks to the adc, it is possible to make a software correc- tion of the vref, in order to calculate the result the adc should have returned in case the vref was more accurate. the idea of this improvement is the following: because there is an eeprom stacked on the product, it is possible to store a linear coefficient which allow a correction of the pro- cess variations. coefficient address the coefficient is stored at the address 0x00 of the serial data eeprom stacked on the at8xeb5114. coefficient format in order to ease the calculation, this coefficient has been stored as a floating decimal number corresponding to table 46. table 46. calibration coefficient storage format it means that if the value is 0x80, the coefficient is equal to 1. if the coefficient is 0x7e, the coefficient is equal to 0,111 1110 in binary which is 0,983 in decimal. during the test, the vref is measured, and the calibration value calculated is stored at the address 0x00 of the stack die in accordance with the table 46 format value. the relation between the coefficient stored, and the true vref measurement are recorded on the table 47. table 47. relation between true vref measurement and coefficient stored into the eeprom bit value 71, 61/2 51/4 41/8 31/16 21/32 11/64 0 1/128 true vref value (v) min 2.300 2.316 2.334 2.353 2.372 2.391 2.409 2.428 2.447 2.466 2.484 typ 2.306 2.325 2.345 2.362 2.381 2.400 2.419 2.438 2.456 2.475 2.494 max 2.316 2.334 2.353 2.372 2.391 2.409 2.428 2.447 2.466 2.484 2.500 value stored 0x7b 0x7c 0x7d 0x7e 0x7f 0x80 0x81 0x82 0x83 0x84 0x85 decimal value 0.961 0.969 0.977 0.984 0.992 1 1.008 1.016 1.023 1.031 1.039
63 4311a?8051?01/05 how to take advantage of the calibration value the coefficient stored on the stacked die allow to determine the conversion result the at8xeb5114 should have returned in case its vref was exactly equal to 2.4v. in order to determine it, a multiplication of the result of the conversion with the coefficient stored in the stack, followed by a shift are sufficient. example vref is 2.36v instead of 2.4v, and only 8 bits are necessary. the value measured during the test 2.36v. so, in accordance with the table 47, the coefficient which has to be stored on the eeprom is 0x7e which corresponds to 0.1111110 in binary, which also corresponds to around 2.36/2.4. if, for example, after a conversion, the addh register contains 0xf0, to know the result the adc should have returned in case the vref was really at 2.4v, the following opera- tions are necessary: 0xf0 * 0x7e = 1111 0000 * 0111 1110 = 0x7620 = 0111 0110 0010 0000. so because of the point on the coefficient, the result is 1110 110 which is 0xec. assembler code example this is an example of assembler code optimized for size and fast recalculation in case 8 bits are sufficient. start_adjustement : mov b,coeff ; coeff mov a,addh ; adc result mul ab ; rlc a ; recover lowest bit mov a,b ; rlc a ; recover result jnc end_fix ; result ok mov a,#0ffh ; overflow end_adjustement : ret the new result is stored on the accumulator. this routine requires 15 bytes + 3 bytes for the long call (lcall). the execution of the subroutine (including the lcall) is 18 cycles in normal case and 19 cycles in case of overflow (less than 10us with a 12 mhz oscillator and the x2 mode). registers table 48. adcon register adcon (s:f3h) adc control register 76543210 quietm psidle aden adeoc adsst sch2 sch1 sch0 bit number bit mnemonic description 7quietm quiet mode (best precision) set to put in quiet mode during conversion. cleared by hardware after completion of the conversion. 6 psidle pseudo idle mode (good precision) set to put in idle mode during conversion. cleared by hardware after completion of the conversion.
64 4311a?8051?01/05 reset value = x000 0000b table 49. adclk register adclk (s:f2h) adc clock prescaler sc reset value = 0000 0000b table 50. addh registe r addh (s:f5h read only) adc data high byte register read only register reset value = 00h 5aden enable/standby mode set to enable adc. clear for standby mode. 4adeoc end of conversion set by hardware when adc result is ready to be read. this flag can generate an interrupt. must be cleared by software. 3 adsst start and status set to start an a/d conversion. cleared by hardware after completion of the conversion. 2-0 sch2:0 selection of channel to convert see table 45 on page 60. 76543210 selref prs 6 prs 5 prs 4 prs 3 prs 2 prs 1 prs 0 bit number bit mnemonic description 7 selref selection and activation of the internal 2.4v voltage reference set to enable the internal voltage reference. clear to disable the internal voltage reference. 6-0 prs6:0 clock prescaler f conv_ck = f ckadc / (2 * prs) if prs=0, f conv_ck = f ckadc / 256 76543210 adat 9 adat 8 adat 7 adat 6 adat 5 adat 4 adat 3 adat 2 bit number bit mnemonic description 7-0 adat9:2 adc result bits 9-2 bit number bit mnemonic description
65 4311a?8051?01/05 table 51. addl register addl (s:f4h read only) adc data low byte register read only register reset value = xxxx xx00b 76543210 ------adat 1adat 0 bit number bit mnemonic description 7-6 - reserved the value read from these bits are indeterminate. do not set these bits. 1-0 adat1:0 adc result bits 1-0
66 4311a?8051?01/05 table 52. adcf register adcf (s:f6h) adc configuration reset value = 0000 0000b 76543210 - - ch5 ch4 ch3 ch2 ch1 ch0 bit number bit mnemonic description 7-6 - not used 5ch5 channel configuration set to use p3.4 as adc input clear to use p3.4 as an other function 4ch4 channel configuration set to use p3.3 as adc input clear to use p3.3 as an other function 3-0 ch3-0 channel configuration set to use p4.x as adc input clear to use p4.x as an other function
67 4311a?8051?01/05 interrupt system the at8xeb5114 has a total of 8 interrupt vectors: two external interrupts (int0 and int1 ), two timer interrupts (timers 0, 1), serial port interrupt, pwmu0, pwmu1 and a/d. these interrupts are shown in figure 31. figure 31. interrupt control system each of the interrupt sources can be individually enabled or disabled by setting or clear- ing a bit in the interrupt enable register (see table 54). this register also contains a global disable bit, which must be cleared to disable all interrupts simultaneously. each interrupt source can also be individually programmed to one of four priority levels by setting or clearing a bit in the interrupt priority register (see table 55) and in the interrupt priority high register (see table 56). table 53 shows the bit values and priority levels associated with each combination. 0 3 high priority interrupt interrupt polling sequence low priority interrupt global disable individual enable tf0 int0 tf1 iph, ip ie0 0 3 0 3 0 3 0 3 0 3 0 3 adc 0 3 0 3 pwmu0 pwmu1 0 1 esb0 int1 ie1 0 1 esb1
68 4311a?8051?01/05 table 53. priority bit level values a low-priority interrupt can be interrupted by a high priority interrupt, but not by another low-priority interrupt. a high-priority interrupt can?t be interrupted by any other interrupt source. if two interrupt requests of different priority levels are received simultaneously, the request of higher priority level is serviced. if interrupt requests of the same priority level are received simultaneously, an internal polling sequence determines which request is serviced. thus within each priority level there is a second priority structure determined by the polling sequence. iph.x ip.x interrupt level priority 0 0 0 (lowest) 011 102 1 1 3 (highest) interrupt name interrupt address vector priority number external interrupt (int0) 0003h 1 timer0 (tf0) 000bh 2 external interrupt (int1) 0013h 3 timer1 (tf1) 001bh 4 pwm0 0023h 5 pwm1 002bh 6 adc 0033h 7
69 4311a?8051?01/05 reset value = 0000 0000b bit addressable table 54. ien0 register ien0 - interrupt enable register (a8h) 7 6 5 4 3 2 1 0 ea eadc ew1 ew0 et1 ex1 et0 ex0 bit number bit mnemonic description 7ea enable all interrupt bit clear to disable all interrupts. set to enable all interrupts. if ea=1, each interrupt source is individually enabled or disabled by setting or clearing its interrupt enable bit. 6 eadc adc interrupt enable clear to disable the adc interrupt. set to enable the adc interrupt. 5ew1 pwm1 enable bit clear to disable pwmu interrupt. set to enable pwmu port interrupt. 4ew0 pwm0 enable bit clear to disable pwmu interrupt. set to enable pwmu port interrupt. 3et1 timer 1 overflow interrupt enable bit clear to disable timer 1 overflow interrupt. set to enable timer 1 overflow interrupt. 2ex1 external interrupt 1 enable bit clear to disable external interrupt 1. set to enable external interrupt 1. 1et0 timer 0 overflow interrupt enable bit clear to disable timer 0 overflow interrupt. set to enable timer 0 overflow interrupt. 0ex0 external interrupt 0 enable bit clear to disable external interrupt 0. set to enable external interrupt 0.
70 4311a?8051?01/05 reset value = x000 0000b bit addressable. table 55. ipl0 register ipl0 - interrupt priority register (b8h) 7 6 5 4 3 2 1 0 - padc pw1 pw0 pt1 px1 pt0 px0 bit number bit mnemonic description 7- reserved the value read from this bit is indeterminate. do not set this bit. 6padc adc interrupt priority bit refer to padch for priority level 5pw1 pwmu1 priority bit refer to pw1h for priority level. 4pw1 pwmu0 priority bit refer to pw1h for priority level. 3pt1 timer 1 overflow interrupt priority bit refer to pt1h for priority level. 2px1 external interrupt 1 priority bit refer to px1h for priority level. 1pt0 timer 0 overflow interrupt priority bit refer to pt0h for priority level. 0px0 external interrupt 0 priority bit refer to px0h for priority level.
71 4311a?8051?01/05 reset value = x000 0000b not bit addressable table 56. iph0 register iph0 - interrupt priority high register (b7h) 7 6 5 4 3 2 1 0 - padch pw1h pw0h pt1h px1h pt0h px0h bit number bit mnemonic description 7- reserved the value read from this bit is indeterminate. do not set this bit. 6 padch adc interrupt priority level most significant bit p adch p adc priority level 0 0 lowest 01 10 1 1 highest 5pw1h pwmu1 priority high bit p w1h pw1 priority level 0 0 lowest 01 10 1 1 highest 4pw1h pwmu0 priority high bit p w1h pw1 priority level 0 0 lowest 01 10 1 1 highest 3pt1h timer 1 overflow interrupt priority high bit p t1h pt1 priority level 0 0 lowest 01 10 1 1 highest 2px1h external interrupt 1 priority high bit p x1h px1 priority level 0 0 lowest 01 10 1 1 highest 1pt0h timer 0 overflow interrupt priority high bit p t0h pt0 priority level 0 0 lowest 01 10 1 1 highest 0px0h external interrupt 0 priority high bit p x0h px0 priority level 0 0 lowest 01 10 1 1 highest
72 4311a?8051?01/05 flash memory as shown figure 32, the flash version of at8xeb5114 implements 4 kbytes of on-chip program/code memory. the flash memory increases eprom and rom functionality by in-circuit electrical era- sure and programming. thanks to the internal charge pump, the high voltage needed for programming or erasing flash cells is generated on-chip using the standard vdd voltage. hardware programming mode is available using specific programming tool. at8xeb5114 features a flash memory containing 4 kbytes of program memory (user space) organized into 128 byte pages, this flash memory is programmable by parallel programming. figure 32. flash memory architecture fm0 memory architecture the flash memory is made up of 4 blocks (see figure 32): ? the memory array (user space) 4 kbytes ? the extra row ? the hardware security bits ? the column latch registers user space this space is composed of a 4 kbytes flash memory organized in 32 pages of 128 bytes. it contains the user?s application code. extra row (xrow) this row is a part of flash memory and has a size of 128 bytes. the extra row may con- tain information for boot loader usage. hardware security byte the hardware security byte space is a part of flash memory and has a size of 1 byte. the 4 msb can be read/written by software, the 4 lsb can only be read by software and written by hardware in parallel mode. column latches the column latches, also part of flash memory, have a size of full page (128 bytes). the column latches are the entrance buffers of the three previous memory locations (user array, xrow and hardware security byte). overview of flash memory operations the cpu interfaces to the flash memory through the fcon register used to: ? map the memory spaces in the adressable space 0fffh 4 kbytes flash memory 0000h hardware security (1 byte) column latches (128 bytes) user space extra row (128 bytes)
73 4311a?8051?01/05 ? launch the programming of the memory spaces ? get the status of the flash memory (busy/not busy) mapping of the memory space by default, the user space is accessed by movc instruction for read only. the column latches space is made accessible by setting the fps bit in fcon register. writing is possible from 0000h to 0fffh, address bits 6 to 0 are used to select an address within a page while bits 14 to 7 are used to select the programming address of the page. the other memory spaces (user, extra row, hardware security) are made accessible in the code segment by programming bits fmod0 and fmod1 in fcon register in accor- dance with table 57. a movc instruction is then used for reading these spaces. table 57. .fm0 blocks select bits launching programming fpl3:0 bits in fcon register are used to secure the launch of programming. a specific sequence must be written in these bits to unlock the write protection and to launch the programming. this sequence is 5xh followed by axh. table 33 summarizes the memory spaces to program according to fmod1:0 bits. figure 33. programming spaces notes: 1. the sequence 5xh and axh must be executing without instructions between then oth- erwise the programming is aborted. 2. interrupts that may occur during programming time must be disable to avoid any spu- rious exit of the idle mode. fmod1 fmod0 fm0 adressable space 0 0 user (0000h-ffffh) 0 1 extra row(ff80h-ffffh) 1 0 hardware security byte (0000h) 1 1 reserved write to fcon operation fpl3:0 fps fmod1 fmod0 user 5 x 0 0 no action ax0 0 write the column latches in user space extra row 5 x 0 1 no action ax0 1 write the column latches in extra row space hardware security byte 5 x 1 0 no action a x 1 0 write the fuse bits space reserved 5 x 1 1 no action a x 1 1 no action
74 4311a?8051?01/05 status of the flash memory the bit fbusy in fcon register is used to indicate the status of programming. fbusy is set when programming is in progress. loading the column latches any number of data from 1 byte to 128 bytes can be loaded in the column latches. this provides the capability to program the whole memory by byte, by page or by any number of bytes in a page. when programming is launched, an automatic erase of the locations loaded in the col- umn latches is first performed, then programming is effectively done. thus no page or block erase is needed and only the loaded data are programmed in the corresponding page. the following procedure is used to load the column latches and is summarized in figure 34: ? disable interrupt and map the column latch space by setting fps bit. ? load the dptr with the address to load. ? load accumulator register with the data to load. ? execute the movx @dptr, a instruction. ? if needed loop the three last instructions until the page is completely loaded. ? unmap the column latch and enable interrupt figure 34. column latches loading procedure note: the last page address used when loading the column latch is the one used to select the page programming address. column latches loading data load dptr= address acc= data exec: movx @dptr, a last byte to load? column latches mapping fps= 1 data memory mapping fps= 0 disable it ea= 0 enable it ea= 1
75 4311a?8051?01/05 programming the flash spaces user the following procedure is used to prog ram the user space and is summarized in figure 35: ? load data in the column latches from address 0000h to 0fffh 1 . ? disable the interrupts. ? launch the programming by writing the data sequence 50h followed by a0h in fcon register (only from fm1). the end of the programming indicated by the fbusy flag cleared. ? enable the interrupts. note: 1. the last page address used when loading the column latch is the one used to select the page programming address. extra row the following procedure is used to program the extra row space and is summarized in figure 35: ? load data in the column latches from address ff80h to ffffh. ? disable the interrupts. ? launch the programming by writing the data sequence 52h followed by a2h in fcon register (only from fm1). the end of the programming indicated by the fbusy flag cleared. ? enable the interrupts.
76 4311a?8051?01/05 figure 35. flash and extra row programming procedure hardware security byte the following procedure is used to program the hardware security byte space and is summarized in figure 36: ? set fps and map hardware byte (fcon = 0x0c) ? disable the interrupts. ? load dptr at address 0000h. ? load accumulator register with the data to load. ? execute the movx @dptr, a instruction. ? launch the programming by writing the data sequence 54h followed by a4h in fcon register (only from fm1). the end of the programming indicated by the fbusy flag cleared. ? enable the interrupts. flash spaces programming disable it ea= 0 launch programming fcon= 5xh fcon= axh end programming enable it ea= 1 column latches loading see figure 34  fbusy cleared? erase mode fcon = 00h
77 4311a?8051?01/05 figure 36. hardware programming procedure reading the flash spaces user the following procedure is used to read the user space and is summarized in figure 37: ? map the user space by writing 00h in fcon register. ? read one byte in accumulator by executing movc a,@a+dptr with a= 0 & dptr= 0000h to ffffh. extra row the following procedure is used to read the extra row space and is summarized in figure 37: ? map the extra row space by writing 02h in fcon register. ? read one byte in accumulator by executing movc a,@a+dptr with a= 0 & dptr= ff80h to ffffh. ? clear fcon to unmap the extra row. hardware security byte flash spaces programming disable it ea= 0 launch programming fcon= 54h fcon= a4h end programming enable it ea= 1 fbusy cleared? erase mode fcon = 00h data load dptr= 00h acc= data exec: movx @dptr, a fcon = 0ch
78 4311a?8051?01/05 the following procedure is used to read the hardware security space and is summarized in figure 37: ? map the hardware security space by writing 04h in fcon register. ? read the byte in accumulator by executing movc a,@a+dptr with a= 0 & dptr= 0000h. ? clear fcon to unmap the hardware security byte. figure 37. reading procedure flash protection from parallel programming the three lock bits in hardware security byte are programmed according to table 58, will provide different level of protection for the on-chip code and data located in flash memory. the only way for write this bits are the parallel mode. table 58. program lock bit warning: security level 2 and 3 should only be programmed after flash and core verification. flash spaces reading flash spaces mapping fcon= 00000xx0b data read dptr= address acc= 0 exec: movc a, @a+dptr erase mode fcon = 00h program lock bits protection description security level lb1 lb0 1 u u no program lock feature enabled. 2up writing flash data from programmer is disabled but still allowed from internal code execution. 3pu writing and reading flash data from programmer is disabled but still allowed from internal code execution.
79 4311a?8051?01/05 registers table 59. fcon: flash control register fcon - flash control register (d1h) reset value= 0000 0000b 76543210 fpl3 fpl2 fpl1 fpl0 fps fmod1 fmod0 fbusy bit number bit mnemonic description 7-4 fpl3:0 programming launch command bits write 5xh followed by axh to launch the programming according to fmod1:0. (see figure 33.) 3fps flash map program space set to map the column latch space in the data memory space. clear to re-map the data memory space. 2-1 fmod1:0 flash mode see table 57 or table 33. 0 fbusy flash busy set by hardware when progr amming is in progress. clear by hardware w hen programming is done. can not be cleared by software.
80 4311a?8051?01/05 at8xeb5114 rom rom structure the at8xeb5114 rom memory is divided in two different arrays:  the code array: 4 kbytes.  the configuration byte:1 byte. hardware configuration byte the configuration byte sets the starting microcontroller options and the security levels. the starting default options are x1 mode, oscillator a. hsb = 1111 xx11b note: whatever the value of rst_osc, the xtal1 input is always validated in order to enter in test modes. table 60. hardware security byte (hsb) hsb (s:efh) power configuration register 7 6 5 4 3 2 1 0 x2 rst_osc1 rst_osc0 rst_oclk - - lb1 lb0 bit number bit mnemonic description 7x2 x2 mode clear to force x2 mode (ckout = oscout) set to use the prescaler mode (ckout = oscout / (2*(16-m))) 6 rst_osc1 oscillator bit 1 on reset 5 rst_osc0 oscillator bit 0 on reset oscillator bit on reset 11: allow osca 10: allow oscb 01: allow oscc 00: reserved 4rst_oclk output clocking signal after reset clear to start the microcontroller with a low level on p3.5 followed by an output clocking signal on p3.5 as soon as the microcontroller is started. this signal has is a 1/3 high 2/3 low signal. its frequency is equal to (ckout / 3). set to start on normal conditions: no signal on p3.5 which is pulled up. 3ckrlrv ckrl reset value if set, the microcontroller starts with the prescaler reset value = xxxx 1000 (oscout = ckout/16). if clear, the microcontroller starts with a prescaler reset value = xxxx 1111 (oscout = ckout/2). 2- reserved 1-0 lb1-0 user program lock bits see table 61 on page 81
81 4311a?8051?01/05 rom lock system the program lock system, when programmed, protects the on-chip program against software piracy. program rom lock bits the lock bits when programmed according to table 61 will provide different level of pro- tection for the on-chip code and data. u: unprogrammed p: programmed table 61. program lock bits program lock bits protection description security level lb1 lb0 1 u u no program lock feature enabled. 3 p u reading rom data from programmer is disabled.
82 4311a?8051?01/05
83 4311a?8051?01/05 stacked eeprom overview the at8xeb5114 features a stacked 2-wire serial data eeprom. the data eeprom allows to save up to 256 bytes. the eeprom is internally connected to p3.6 and p3.7 which are respectively connected to the sda and the scl pins. protocol in order to access this memory, it is necessary to use software subroutines according to the at24c02 datasheet. nevertheless, because the internal pull-up resistors of the at8xeb5114 is quite high (around 100k ? ), the protocol should be slowed in order to be sure that the sda pin can rise to the high level before reading it. another solution to keep the access to the eeprom in specification is to work with a software pull-up. using a software pull-up, consists of forcing a low level at the output pin of the microcon- troller before configuring it as an input (high level). the c51 the ports are ?quasi-bidirectional? ports. it means that the ports can be config- ured as output low or as input high. in case a port is configured as an output low, it can sink a current and all internal pull-ups are disconnected. in case a port is configured as an input high, it is pulled up with a strong pull-up (a few hundreds ohms resistor) for 2 clock periods. then, if the port is externally connected to a low level, it is only kept high with a weak pull up (around 100k ? ), and if not, the high level is latched high thanks to a medium pull (around 10k ? ). thus, when the port is configured as an input, and when this input has been read at a low level, there is a pull-up of around 100k ? , which is quite high, to quickly load the sda capacitance. so in order to help the reading of a high level just after the reading of a low level, it is possible to force a transition of the sda port from an input state (1), to an output low state (0), followed by a new transition from this output low state to input state; in this case, the high pull-up has been replaced with a low pull-up which warran- ties a good reading of the data.
84 4311a?8051?01/05 electrical characteristics absolute maximum ratings (*) power consumption measurement since the introduction of the first c51 devices, every manufacturer made operating icc measurements under reset, which made sense for the designs where the cpu was run- ning under reset. in our new devices, the cp u is no longer active during reset, so the power consumption is very low and this is not really representative of what will happen in the customer?s system. thus, while keeping measurements under reset, we present a new way to measure the operating icc: using an internal test rom, the following code is executed: label: sjmp label (80 fe) ports 3, 4 are disconnected, rst = vcc, xtal2 is not connected and xtal1 is driven by the clock. this is much more representative of the real operating icc. dc parameters for low voltage t a = 0 c to +70 c; v ss = 0 v; v cc = 3 v to 3.6 v; f = 0 to 24 mhz. t a = -40 c to +85 c; v ss = 0 v; v cc = 3 v to 3.6 v; f = 0 to 24 mhz. ambient temperature under bias: c = commercial..................................................... 0 c to 70 c i = industrial ....................................................... -40 c to 85 c storage temperature ................................... -65 c to + 150 c voltage on v cc to v ss .....................................-0.5 v to + 4.6 v voltage on any pin to v ss .......................-0.5 v to v cc + 0.5 v power dissipation .............................................................. 1 w electro-static discharge voltage 1500 v *notice: s tresses at or above those listed under ?abso- lute maximum ratings? may cause permanent damage to the device. this is a stress rating only and functional operation of the device at these or any other conditions above those indicated in the operational sections of this specification is not implied. exposure to absolute maximum rating conditions may affect device reliability. power dissipation value is based on the maxi- mum allowable die temperature and the thermal resistance of the package. table 1. dc parameters for low voltage symbol parameter min typ max unit test conditions v il input low voltage -0.5 0.8 v v ih input high voltage except xtal1, rst 2 v cc + 0.5 v v ih1 input high voltage, xtal1, rst 0.7 v cc v cc + 0.5 v v ol output low voltage, ports 3, 4 (6) 0.3 0.45 1.0 v v v i ol = 100 a i ol = 1.6 ma i ol = 3.2 ma v oh output high voltage, ports 3, 4. (6) 0.9 v cc v cc - 0.7 v cc - 1.4 v v v i oh = -10 a i oh =-30 a i oh = -50 a
85 4311a?8051?01/05 v oh2 output high voltage, ports 3, 4. (6) mode push pull 0.9v cc v cc - 0.7 v cc - 1.5 v v v i oh = -100 a i oh = - 1 ma i oh = - 2 ma i il logical 0 input current ports 3 and 4 (7) -50 a vin = 0.45 v i il input leakage current 10 a 0.45 v < vin < v cc i tl logical 1 to 0 transition current, ports 3, 4 (8) -650 a vin = 2.0 v r rst rst pull up resistor 50 90 (5) 200 k ? cio capacitance of i/o buffer 10 pf fc = 1 mhz t a = 25 c i pd power down current 50 200 av cc = 3.0 v to 3.6 v (3) f oscb oscb unlocked frequency 10.8 12 13.2 mhz with ideal r and c f oscb oscb locked frequency 11.5 12 12.5 mhz with ideal r and c f osc c oscc frequency 8.4 14 19.6 mhz i cc under reset power supply current maximum values, x1 mode, osca oscillator (9) 4 ma v cc = 3.3 v (1) osca + prescaler i cc operating power supply current maximum values, x1 mode, osca oscillator (9) 0.4*f+3 ma v cc = 3.3 v (10) f in mhz i cc idle power supply current maximum values, x1 mode, osca oscillator (9) 6 ma v cc = 3.3 v (2) i cc under reset power supply current maximum values, x1 mode, oscb oscillator (9) 900 ua v cc = 3.3 v (1) oscb + prescaler i cc operating power supply current maximum values, x1 mode, oscb oscillator (9) 5mav cc = 3.3 v (10) i cc idle power supply current maximum values, x1 mode, oscb oscillator (9) 4.8 ma v cc = 3.3 v (2) i cc under reset power supply current maximum values, x1 mode, oscc oscillator (9) 650 a v cc = 3.3 v (1) oscc + prescaler i cc operating power supply current maximum values, x1 mode, oscc oscillator (9) 5ma v cc = 3.3 v (10) i cc idle power supply current maximum values, x1 mode, oscc oscillator (9) 4.8 ma v cc = 3.3 v (2) v ret supply voltage during power down mode 2.7 v vpfdp power fail high level threshold 2.6 2.8 2.95 v vpfdm power fail low level threshold (default) 2.45 2.55 2.7 v power fail hysteresis vpfdp - vpfdm 150 250 350 mv t g glitch maximum time 100 ns vcc down to 2.5 v table 1. dc parameters for low voltage (continued) symbol parameter min typ max unit test conditions
86 4311a?8051?01/05 notes: 1. i cc under reset is measured with all output pins disconnected; xtal1 driven with t clch , t chcl = 5 ns (see figure 42.), v il = v ss + 0.5 v, v ih = v cc - 0.5v; xtal2 n.c.; vpp = rst = v cc . i cc would be slightly higher if a crystal oscillator used 2. idle i cc is measured with all output pins disconnected; xtal1 driven with t clch , t chcl = 5 ns, v il = v ss + 0.5 v, v ih = v cc - 0.5 v; xtal2 n.c; vpp = rst = v ss (see figure 40.). 3. power down i cc is measured with all output pins disconnected; vpp = v ss ; xtal2 nc.; rst = v cc (see figure 41.). 4. not applicable 5. typical are based on a limited number of samples and are not guaranteed. the values listed are at room temperature and 3.3v. 6. if i ol exceeds the test condition, v ol may exceed the related specification. pins are not guaranteed to sink current greater than the listed test conditions. 7. for other values, please contact your sales office. 8. when port configuration have weak pull-up activated. 9. when port configuration is quasi-bidirectional. 10. operating i cc is measured with all output pins disconnected; xtal1 driven with t clch , t chcl = 5 ns (see figure 42.), v il = v ss + 0.5 v, v ih = v cc - 0.5v; xtal2 n.c.; rst = v cc ;. the internal rom runs the code 80 fe (label: sjmp label). i cc would be slightly higher if a crystal oscillator is used. measurements are made with otp products when possible, which is the worst case. figure 38. i cc test condition, under reset figure 39. operating i cc test condition t r supply rise time 1us 1s table 1. dc parameters for low voltage (continued) symbol parameter min typ max unit test conditions v cc i cc (nc) clock signal all other pins are disconnected. rst xtal2 xtal1 v ss v cc v cc i cc (nc) clock signal all other pins are disconnecte d. rst xtal2 xtal1 v ss v cc reset = vss after a high pulse during at least 24 clock cycles v cc
87 4311a?8051?01/05 figure 40. i cc test condition, idle mode figure 41. i cc test condition, power-down mode figure 42. clock signal waveform for i cc tests in active and idle modes rst xtal2 xtal1 v ss v cc i cc (nc) v cc all other pins are disconnected . clock signal reset = vss after a high pulse during at least 24 clock cycles v cc rst xtal2 xtal1 v ss v cc i cc v cc r eset = vss after a high pulse d uring at least 24 clock cycles v cc all other pins are disconnected . v cc -0.5v 0.45v 0.7v cc 0.2v cc -0.1 t clch t chcl t clch = t chcl = 5ns.
88 4311a?8051?01/05 dc parameters for a/d converter t a = 0 c to +70 c; v ss = 0 v; v cc = 3v to 3,6 v; f = 0 to 24mhz. t a = -40 c to +85 c; v ss = 0 v; v cc = 3v to 3,6 v; f = 0 to 24mhz. table 2. dc parameters for low voltage note: (1) with lsb = 2.4/1024 = 2.4mv, typical integral linearity is: ac parameters explanation of the ac symbols each timing symbol has 5 characters. the firs t character is always a ?t? (stands for time). the other characters, depending on their positions, stand for the name of a sig- nal or the logical status of that signal. the following is a list of all the characters and what they stand for. example:t xhdv = time from clock rising edge to input data valid. t a = 0 to +70 c (commercial temperature range); v ss = 0 v; 3 v < v cc < 3.6 v; -l range. t a = -40 c to +85 c (industrial temperature range); v ss = 0 v; 3 v < v cc < 3.6 v; -l range. table 3. gives the maximum applicable load capacitance for port 1, 3 and 4. timings will be guaranteed if these capacitances are res pected. higher capacitance values can be used, but timings will then be degraded. table 3. load capacitance versus speed range, in pf symbol parameter min typ max unit test conditions resolution 10 bit avin analog input voltage vss - 0.2 vcc + 0.2 v rref resistance between vref and vss 13 18 24 ko hm vref value of integrated voltage source 2.30 2.40 2.50 v vref drift vref voltage drift over temperature 150 uv/ c lref load on integrated voltage source 10 ko hm cai analog input capacitance 60 pf during sampling integral non linearity 1 2 lsb with ideal external ref (1) differential non linearity 0.5 1 lsb offset error -2 2 lsb input source impedance 1 ko hm for 10 bit resolution at maximum speed 24 , vref ? () 24 , 3 ? 10 ------------------------------- -l port 3 & 4 60
89 4311a?8051?01/05 table 4. max frequency for derating formula regarding the speed grade external clock drive characteristics (xtal1) external clock drive waveforms figure 43. external clock drive waveforms a/d converter notes: 1. for 10 bits resolution -l x1 mode -l x2 mode freq (mhz) 40 (1) 1. oscillator speed is limited to 24 mhz 20 t (ns) 25 50 symbol parameter min max units t clcl oscillator period 25 ns t chcx high time 5 ns t clcx low time 5 ns t clch rise time 5 ns t chcl fall time 5 ns t chcx /t clcx cyclic ratio in x2 mode 40 60 % vcc-0.5 v 0.45 v 0.7vcc 0.2vcc-0.1 v tchcl tclcx tclcl tclch tchcx symbol parameter min typ max units conversion time 11 clock periods (1 for sampling, 10 for conversion) fconv_ck clock conversion frequency 550 (1) khz sampling frequency 10 50 kilo samples per second
90 4311a?8051?01/05 pwm outputs ac testing input/output waveforms figure 44. ac testing input/output waveforms ac inputs during testing are driven at v cc - 0.5 for a logic ?1? and 0.45v for a logic ?0?. timing measurement are made at v ih min for a logic ?1? and v il max for a logic ?0?. float waveforms figure 45. float waveforms for timing purposes as port pin is no longer floating when a 100 mv change from load voltage occurs and begins to float when a 100 mv change from the loaded v oh /v ol level occurs. i ol /i oh 20ma. clock waveforms valid in normal clock mode. in x2 mode xtal2 signal must be changed to xtal2 divided by two. symbol parameter min typ max units tr rise time of pwm outputs 60 ns (load 300 pf) can be slower tf fall time of pwm outputs 30 ns (300 pf) can be slower 0.45 v vcc-0.5 v 0.2vcc+0.9 0.2vcc-0.1 input/output vol+0.1 v voh-0.1 v float vload vload+0.1 v vload-0.1 v
91 4311a?8051?01/05 figure 46. clock waveforms this diagram indicates when signals are clocked internally. the time it takes the signals to propagate to the pins, however, ranges from 25 to 125 ns. this propagation delay is dependent on variables such as temperatur e and pin loading. propagation also varies from output to output and component. typically though (t a =25 c fully loaded) rd and wr propagation delays are approximately 50 ns. the other signals are typically 85 ns. propagation delays are incorporated in the ac specifications. clock xtal2 internal state4 state5 state6 state1 state2 state3 state4 state5 serial port shift clock port operation txd (mode 0) rxd sampled rxd sampled p1, p3, p4 pins sampled p1, p3, p4 pins sampled mov dest port (p1, p3, p4) (includes int0, int1, to, t1) old data new data p1p2 p1p2 p1p2 p1p2 p1p2 p1p2 p1p2 p1p2
93 4311a?8051?01/05 typical application figure 47. typical application diagram digital i/o vcc r c ee p3.5/w1m0 p3.4/t0/ain5 nc pfc control p3.6 p3.7 nc vss vss vss vss vss p3.3/w0m2/ain4 p3.2/int0 p3.1/w0m1 p3.0/w0m0 lamp driver high lamp driver low over current nc p4.3/ain3 p4.2/ain2 p4.1/ain1 p4.0/ain0 pfc measurement dc voltage lamp detection lamp current analog i/o rst nc xtal1 nc xtal2 vcc vref vref vssa vcca
94 4311a?8051?01/05 ordering information table 7. possible order entries part number memory size supply voltage temperature range max frequency package packing at83eb5114xxxtgril 4kb rom 3 to 3.6v industrial 40 mhz s020 reel AT89EB5114-TGSIL 4kb flash 3 to 3.6v industrial 40 mhz so20 stick
95 4311a?8051?01/05 package drawings so20
printed on recycled paper. disclaimer: atmel corporation makes no warranty for the use of its products , other than those expressly contained in the company?s standar d warranty which is detailed in atmel?s terms and conditions locate d on the company?s web site. the company assumes no responsibi lity for any errors which may appear in this document, reserves the right to change devices or specifications detailed herein at any time wi thout notice, and does not make any commitment to update the information contained herein. no licenses to patents or other intellectual property of atmel are granted by the company in connection with the sale of atmel produc ts, expressly or by implicati on. atmel?s products are not aut horized for use as critical components in life support devices or systems. atmel corporation atmel operations 2325 orchard parkway san jose, ca 95131 tel: 1(408) 441-0311 fax: 1(408) 487-2600 regional headquarters europe atmel sarl route des arsenaux 41 case postale 80 ch-1705 fribourg switzerland tel: (41) 26-426-5555 fax: (41) 26-426-5500 asia room 1219 chinachem golden plaza 77 mody road tsimshatsui east kowloon hong kong tel: (852) 2721-9778 fax: (852) 2722-1369 japan 9f, tonetsu shinkawa bldg. 1-24-8 shinkawa chuo-ku, tokyo 104-0033 japan tel: (81) 3-3523-3551 fax: (81) 3-3523-7581 memory 2325 orchard parkway san jose, ca 95131 tel: 1(408) 441-0311 fax: 1(408) 436-4314 microcontrollers 2325 orchard parkway san jose, ca 95131 tel: 1(408) 441-0311 fax: 1(408) 436-4314 la chantrerie bp 70602 44306 nantes cedex 3, france tel: (33) 2-40-18-18-18 fax: (33) 2-40-18-19-60 asic/assp/smart cards zone industrielle 13106 rousset cedex, france tel: (33) 4-42-53-60-00 fax: (33) 4-42-53-60-01 1150 east cheyenne mtn. blvd. colorado springs, co 80906 tel: 1(719) 576-3300 fax: 1(719) 540-1759 scottish enterprise technology park maxwell building east kilbride g75 0qr, scotland tel: (44) 1355-803-000 fax: (44) 1355-242-743 rf/automotive theresienstrasse 2 postfach 3535 74025 heilbronn, germany tel: (49) 71-31-67-0 fax: (49) 71-31-67-2340 1150 east cheyenne mtn. blvd. colorado springs, co 80906 tel: 1(719) 576-3300 fax: 1(719) 540-1759 biometrics/imaging/hi-rel mpu/ high speed converters/rf datacom avenue de rochepleine bp 123 38521 saint-egreve cedex, france tel: (33) 4-76-58-30-00 fax: (33) 4-76-58-34-80 e-mail literature@atmel.com web site http://www.atmel.com 4311a?8051?01/05 /xm ? atmel corporation 2004. all rights reserved. atmel?, logo and combinations thereof are registered trademarks, and everywhere you are(sm) are the trademarks of atmel corporatio n or its subsidiaries. other terms and product names may be trademarks of others.


▲Up To Search▲   

 
Price & Availability of AT89EB5114-TGSIL

All Rights Reserved © IC-ON-LINE 2003 - 2022  

[Add Bookmark] [Contact Us] [Link exchange] [Privacy policy]
Mirror Sites :  [www.datasheet.hk]   [www.maxim4u.com]  [www.ic-on-line.cn] [www.ic-on-line.com] [www.ic-on-line.net] [www.alldatasheet.com.cn] [www.gdcy.com]  [www.gdcy.net]


 . . . . .
  We use cookies to deliver the best possible web experience and assist with our advertising efforts. By continuing to use this site, you consent to the use of cookies. For more information on cookies, please take a look at our Privacy Policy. X